New Parser

Reporter: JoshDreamland  |  Status: open  |  Last Modified: August 28, 2021, 12:18:34 pm
Step one: Remove dependencies on JDI from the Lexer.

This gives ENIGMA a custom representation of JDI macros. This functionality is untested. Actually, the only test for the lexer right now is misnamed, but I need to shelve this and fix something in RGM.

This commit integrates the new lexer into the old parser by re-stringifying the lex after syntax checking. It replaces the syntax checker with a call to AST::ParseAST. However, this method is NOT YET IMPLEMENTED, meaning no syntax checking happens as of this commit.

In all likelihood there are remaining problems tokenizing strings, etc. Also, the INCREMENT and DECREMENT tokens cannot be programmatically removed from the token trie at this time.

Theoretically, though, valid games should still build as of this commit. I expect the CI to suggest otherwise.

BEFORE WE COMMIT THIS: The missing methods on AST must be authored, building the actual tree. This change puts the compiler where I thought it was when I started this task.


Codecov Report

Merging #2167 (6707de7) into master (fad7d5f) will increase coverage by 2.97%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2167      +/-   ##
+ Coverage   32.84%   35.81%   +2.97%     
  Files         199      211      +12     
  Lines       19085    20894    +1809     
+ Hits         6269     7484    +1215     
- Misses      12816    13410     +594     
Impacted Files Coverage Δ
...tem/SHELL/Universal_System/Object_Tiers/object.cpp 27.73% <0.00%> (-2.41%) ⬇️
ENIGMAsystem/SHELL/Platforms/xlib/XLIBwindow.cpp 45.84% <0.00%> (-1.29%) ⬇️
...LL/Universal_System/Resources/sprites_internal.cpp 75.43% <0.00%> (-0.93%) ⬇️
ENIGMAsystem/SHELL/SHELLmain.cpp 100.00% <0.00%> (ø)
...MAsystem/SHELL/Platforms/General/POSIX/Utility.cpp 100.00% <0.00%> (ø)
.../SHELL/Graphics_Systems/OpenGL-Common/GLSLshader.h 100.00% <0.00%> (ø)
...llision_Systems/Polygon/polygon_collision_util.cpp 68.66% <0.00%> (ø)
...ELL/Collision_Systems/Polygon/placeholderlinks.cpp 0.00% <0.00%> (ø)
ENIGMAsystem/SHELL/Collision_Systems/actions.h 100.00% <0.00%> (ø)
...LL/Universal_System/Resources/polygon_internal.cpp 79.46% <0.00%> (ø)
... and 23 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fad7d5f...6707de7. Read the comment docs.

Please sign in to post comments, or you can view this issue on GitHub.