Version 1.0
Copyright © 2022 Lowell D. Thomas
Python APG
 … an ABNF Parser Generator
Functions
apg_py.api.rule_dependencies Namespace Reference

Functions

def rule_dependencies (rules, udts, rule_names, udt_names)
 Determine the rule dependencies and recursive types for each rule. More...
 
def display_deps (rule_deps, rules, udts, alpha=True)
 Display the rule dependencies. More...
 

Function Documentation

◆ display_deps()

def apg_py.api.rule_dependencies.display_deps (   rule_deps,
  rules,
  udts,
  alpha = True 
)

Display the rule dependencies.

Parameters
rule_depsThe rule dependencies. The returned object from the rule_dependencies() function.
rulesThe rules from the syntax & semantic phases.
udtsThe UDTs from the syntax & semantic phases.
alphaIf True (default), rules are listed alphabetically. Otherwise, they are listed in the order in which they appear in the grammar syntax.
Returns
The display string.

Definition at line 99 of file rule_dependencies.py.

◆ rule_dependencies()

def apg_py.api.rule_dependencies.rule_dependencies (   rules,
  udts,
  rule_names,
  udt_names 
)

Determine the rule dependencies and recursive types for each rule.

Parameters
rulesThe rules from the syntax & semantic phases.
udtsThe UDTs from the syntax & semantic phases.
rule_namesThe NameList object (see class Api)for looking up rule name indexes.
udt_namesThe NameList object for looking up UDT name indexes.
Returns
The rule dependencies object.

Definition at line 7 of file rule_dependencies.py.

Python APG, Version 1.0, is licensed under the 2-Clause BSD License,
an Open Source Initiative Approved License.