Is there a way to take the S-Expression output from Antlr4 and display it graphically as a treeview in Windows 10?
here's my grammar file for antlr4:
https://github.com/antlr/grammars-v4/blob/master/vhdl/vhdl.g4
here's my vhdl program to parse with antrl4:
entity testbench is
end entity;
architecture beh of testbench is
begin
end architecture;
Here's my S-Expression Output from Antlr4 for the vhdl file:
(design_file (design_unit context_clause (library_unit (primary_unit
(entity_declaration entity
(identifier testbench) is entity_header entity_declarative_part end entity ;))))
(design_unit context_clause (library_unit
(secondary_unit (architecture_body architecture (identifier beh) of
(identifier testbench) is architecture_declarative_part
begin architecture_statement_part end architecture ;)))) <EOF>)
I want to see the s-expression output from antlr in a treeview with collapable nodes, something like this:
https://www.c-sharpcorner.com/article/treeview-control-in-C-Sharp/
Is there a windows 10 program for graphically browsing the s-expressions output of antrl4 as a graphical treeview?
Ideally I want something that reads the antrl s-expressions generated by -tree flag, and the tokens list generated by -tokens flag, and merges them together for display in a GUI treeview so that when i click on a node of the s-expression in the tree and i get the information in the token file as well...
For Java target, use Trees.inspect(tree, parser)
. It'll pop up a window with the tree view. Or use Intellij/jetbrains plugin
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.