Louis Dubois
abdbabe429
fix: Propagate debug flag on loading grammar from cache
The debug flag is already saved in the cached file, but is not
resumed on loading the dumped file. To solve that,
- add argument `debug` to parser_fronteds.WithLexer.deserialize
- add argument `debug` lalr_parser.LALR_Parser.deserialize
- propagate the value of the `debug` option on resuming a cached
grammar, in lark.Lark._load
4 years ago
Chanic Panic
24434ec5ff
Add documentation for working with the SPPF
4 years ago
Erez Sh
156bd7577f
Adjustments and fixes for PR
4 years ago
Chanic Panic
50c9cda6b5
Pass list to on_cycle instead of function
4 years ago
Erez Sh
88d4659c29
Improvements to puppet + other small stuff
4 years ago
Chanic Panic
9db869cc80
Add PackedData class
4 years ago
Chanic Panic
9c967fafb0
Add ambiguity='forest' option
4 years ago
Chanic Panic
607f984523
Create TreeForestTransformer
4 years ago
Chanic Panic
93d70e8a41
Replace ForestToTreeVisitors with ForestToParseTree
4 years ago
Chanic Panic
4adc871bf1
Add ForestTransformer
4 years ago
Chanic Panic
67ae0e2b16
Moderate updates and improvements to ForestVisitor
- add methods for visiting intermediate nodes
- add method to notify subclass of cycles
- support returning iterables of nodes from visit*node_in functions
- remove result and visit return value
- also add children property to PackedNode
4 years ago
Erez Sh
fe89296193
Improved load_grammar's error messages, and added tests
4 years ago
Erez Sh
b87acedac4
Fixed docs. Added support for hashing ParserPuppet
4 years ago
Chanic Panic
b076efadff
Create CompleteForestToAmbiguousTreeVisitor
4 years ago
Erez Sh
288078a6a0
Corrections to PR
4 years ago
Erez Sh
0c47b981fc
Bugfix: Infinite loop on mishandled $END token in on_error (Issue #656 )
4 years ago
Sasank Chilamkurthy
452f3fc061
complete sphinx autodoc
4 years ago
Erez Sh
39fb4c0f3e
Bugfix and warn on ambiguous intermediate nodes, based on PR #651
4 years ago
Erez Sh
af3bedd39d
Adjustments to logging PR
4 years ago
Erez Sh
02d57bc32a
Small adjustments to PR
4 years ago
MegaIng1
cb2d9cded0
Refactored ParserPuppet, added stubs
4 years ago
MegaIng1
2e160c046e
Correction for python2.7 (LalrPuppet-> new style class)
4 years ago
MegaIng1
a7bcd0bc2d
Added `accepts` attribute to `UnexpectedToken` and update stubs
4 years ago
MegaIng1
28e0a86f38
Small improvements for debug info
4 years ago
pwwang
2a73afd355
Change LOGGER to logger
4 years ago
Erez Sh
601f050645
Added docs for ParserPuppet
4 years ago
pwwang
5c8a25c733
Avoid using root logger
4 years ago
Erez Sh
cc1092bd53
Refactored puppet + small fixes
4 years ago
Erez Sh
66a073d0aa
Added support for error handling, using a puppet parser.
TODO: Add docs
4 years ago
Erez Sh
4463524b3a
Puppet initial
4 years ago
Erez Sh
e12e1ccbf9
Minor refactor
4 years ago
Erez Sh
3bee21051e
Reverted changes regarding EOF
4 years ago
Erez Sh
c56112eea3
Added debug prints for parser error (in debug mode)
4 years ago
Erez Sh
dcc98241c1
Improved handling and performance of large grammars
4 years ago
Erez Sh
3a04f49860
Fixed 'end_pos' for xearley, 2nd try (issue #534 )
5 years ago
Erez Sh
a84788087b
Fixed 'end_pos' for xearley (issue #534 )
5 years ago
Erez Sh
3995ad913a
Tiny tiny cleanup
5 years ago
Erez Sh
cf7479f186
Post-merge fixed for end_symbol, + two more tests (Issue #237 )
5 years ago
Erez Sh
fcdba441b4
Better error message for reduce/reduce conflict (Issue #135 )
5 years ago
Erez Sh
b2f1b3bf7c
Small fixes
5 years ago
Erez Sh
b9c81a5450
Refactor: Simplify code by assuming rule.options is never None
5 years ago
Erez Sh
99a27663f6
Better error message
5 years ago
Erez Sh
0a4530b942
Improved Earley error on EOF (Issue #457 )
5 years ago
Erez Sh
94da6c52b8
Refactored the Earley code to make it thread-safe (Issue #454 )
5 years ago
Erez Shinan
deb325acb4
Pydot now not necessary for earley debug, shows warning instead (Issue #443 )
5 years ago
night199uk
dc3c009dca
Tweak the Earley ambiguity algorithm to correctly prefer earlier branches
5 years ago
night199uk
d845aa3bf1
Add debug flag to Early and XEarley to allow dumping the SPPF
5 years ago
Erez Shinan
8466981c08
Cleanup
5 years ago
Raekye
0c59cba3f5
implement DeRemer and Pennello's lookahead algorithm for LALR(1)
5 years ago
Raekye
6f412c25b7
LALR optimizations and profiling
5 years ago