Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
badw-it
DHParser
Commits
70b905aa
Commit
70b905aa
authored
Mar 14, 2018
by
eckhart
Browse files
- some typos corrected
parent
8f1a6bb3
Changes
4
Show whitespace changes
Inline
Side-by-side
DHParser/compile.py
View file @
70b905aa
...
...
@@ -27,7 +27,7 @@ code or, as in the case of DHParser's EBNF-compiler, Python
source code.
Function ``compile_source`` invokes all stages of the compilation
process, i.e. preprocessing, parsing, CST to AST-transformation
process, i.e. pre
-
processing, parsing, CST to AST-transformation
and compilation.
See module ``ebnf`` for a sample of the implementation of a
...
...
DHParser/parse.py
View file @
70b905aa
...
...
@@ -862,7 +862,8 @@ class PlainText(Parser):
"""
Parses plain text strings. (Could be done by RegExp as well, but is faster.)
Example:
Example::
>>> while_token = PlainText("while")
>>> Grammar(while_token)("while").content
'while'
...
...
DHParser/syntaxtree.py
View file @
70b905aa
...
...
@@ -19,7 +19,7 @@
"""
Module ``syntaxtree`` defines the ``Node``-class for syntax trees as well
as an abstract base class for parser-objects. The latter is defined
here, bec
u
ase node-objects refer to parser-objects. All concrete
here, beca
u
se node-objects refer to parser-objects. All concrete
parser classes are defined in the ``parse`` module.
"""
...
...
TODO.md
View file @
70b905aa
...
...
@@ -25,14 +25,14 @@ Challenges:
2.
...but discarded or discardable nodes are not the same as a not matching parser.
Possible solution would be to introduce a dummy/zombie-Node that will be discarded
by the calling Parser, i.e. Zero
or
More, Series etc.
by the calling Parser, i.e. Zero
Or
More, Series etc.
3.
Two kinds of conditions for dis
3.
Two kinds of conditions for dis
carding...?
4.
Capture/Retrieve/Pop - need the parsed data even if the node would otherwise
be discardable (Example: Variable Delimiters.) So, either:
a. temporarily suspend discarding by
g
ramma-object-flag set and cleared by
a. temporarily suspend discarding by
G
ramma
r
-object-flag set and cleared by
Capture/Retrieve/Pop. Means yet another flag has to be checked every time
the decision to discard or not needs to be taken...
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment