Erez Shinan
a798dec779
Fix to new serializer code (Discussed in issue #349 )
5 years ago
Erez Shinan
5ab12b031c
Added transformer, postlex arguments to standalone
5 years ago
Erez Shinan
ae51402cc7
Added serializer test
5 years ago
Erez Shinan
3c64c56bcd
All tests passing
5 years ago
Erez Shinan
94e15fb6f7
Mid work. Almost stable
5 years ago
Erez Shinan
bd75bf2dff
Refactor - callbacks are now {rule: callback}, instead of a Callback object referenced by Rule.alias
5 years ago
Erez Shinan
475312c608
Bugfix in tools.nearley: Added support for null keyword (Issue #342 )
6 years ago
Erez Shinan
20329e0bf5
Bugfix in tools.nearley: Backslash now handled correctly in strings (Issue #341 )
6 years ago
night199uk
80a09697fe
Rebuild the way Earley prioritizes ambiguities
- Makes rule ordering the default ambiguity tie breaker.
E.g.
start: a | b
a: "A"
b: "A"
will return:
start
a
start: b | a
a: "A"
b: "A"
will return
start
b
- Replaces the ambiguity='resolve__antiscore_sum' with a separate option: 'priority'.
The priority option has 4 values: 'auto', 'none', 'normal', 'invert'.
'Auto' maps to 'Normal' for CYK and Earley and 'None' for LALR.
'None' filters your priorities and ignores them. This saves some extra tree walking on Earley.
'Normal' uses your priorities untouched, mimicing the old behaviour.
'Invert' negates your priorities, emulating the old 'resolve__antiscore_sum' behaviour.
This allows you to use priority logic even when ambiguity=='explicit', to get a better idea
of the shape of your tree; and to easily disable priorities without removing them from the
grammar for testing (or performance).
- ambiguity='explicit' now correctly returns an ambiguous tree again, as 0.6 did.
6 years ago
Jan Rydzewski
3ef84318b1
Removed unused imports and variables
6 years ago
Erez Shinan
0881fe122f
Updated mention of GPL for standalone tool (Issue #247 )
6 years ago
Erez Shinan
c85098e090
Small refactoring in standalone
6 years ago
Erez Shinan
720372a386
Standalone parser now uses contextual lexer instead of traditional one (Issue #212 )
It should be easy to allow the user to choose between them, but perhaps unnecessary, as the one and only benefit of the traditional parser is a tiny performance advantage.
6 years ago
Erez Shinan
53a66132ba
Added visitors & transformers to standalone (Issue #223 )
6 years ago
Erez Shinan
37cfe5c9f3
BUGFIX: Standalone parser didn't retain filter_out values for terminals (Issue #222 )
6 years ago
Erez Shinan
843da8e809
Fixed bugs in the standalone generator (Issue #212 )
6 years ago
Erez Shinan
dee5ac776d
Fix for Python 3.7
6 years ago
Erez Shinan
c77934f6a2
Fixed nearley
6 years ago
Erez Shinan
33caa391d5
Breaking backwards compatibility:
* Removed the scanless parsing feature (dynamic lexing is king)
* Default LALR lexer is now contextual
6 years ago
Erez Shinan
b951b5f79c
Significant reduction in memory consumption (Saving only parse-table instead of analysis instance)
6 years ago
Erez Shinan
eba4a604cb
Added tests for standalone generator
7 years ago
Erez Shinan
07f45a0bd3
Style fixes
7 years ago
Erez Shinan
e697c266a7
Standalone: Significantly reduced generated code size
7 years ago
Erez Shinan
9b0672fda6
Standalone tools now supports postlex
7 years ago
Erez Shinan
a409f2835c
Corrections to the standalone tool
7 years ago
Erez Shinan
5ac4120b71
Stand-alone tool working for LALR+traditional lexer (first commit)
7 years ago
Erez Shinan
ad30c324f5
Added support for all RE flags.
7 years ago
Erez Shinan
d846627fb7
A few fixes to escaping
7 years ago
Erez Shinan
eed2a0fd78
Minor fix: Removed printing in new nearley tests
7 years ago
Kaspar Emanuel
b491138d9a
Make nearley tool main testable and test it
7 years ago
Kaspar Emanuel
809ac8c9ea
Switch to codecs.open for nearley tool
7 years ago
Kaspar Emanuel
3940812575
Fix spelling of TransformNearley class
7 years ago
Erez Shinan
2bd23b1b62
Style fixes
7 years ago
Kaspar Emanuel
c0063e4d82
Make tracking includes more logical in nearley tool
7 years ago
Kaspar Emanuel
4539152b32
Refactor nearley builtin and include
7 years ago
Kaspar Emanuel
3ea0b35c9f
Fix nearley multi includes
7 years ago
Kaspar Emanuel
a87bcf3097
Convert nearley css test into unit test
7 years ago
Kaspar Emanuel
e8c02951e4
Add support for nearley @include
7 years ago
Erez Shinan
7d3e00666b
Nearley-to-Lark Works. Now using js2py as code generator
8 years ago
Erez Shinan
007b2174df
Still working on Nearley
8 years ago
Erez Shinan
d4140d5e6c
Nearley -> Lark tool working for tests with js2py
8 years ago
Erez Shinan
c1968b7e30
Fixed tools.nearley (converter)
8 years ago
Erez Shinan
b7dcfbca58
Tools can now be installed via pip
8 years ago