Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiler output should include reference to the original markup #530

Open
mathisonian opened this issue Jun 11, 2019 · 0 comments · May be fixed by #611
Open

Compiler output should include reference to the original markup #530

mathisonian opened this issue Jun 11, 2019 · 0 comments · May be fixed by #611

Comments

@mathisonian
Copy link
Member

Is your feature request related to a problem? Please describe.
The AST is a useful representation of idyll markup, however it is difficult to map this back onto substrings in the original markup. Each AST node should include a reference to the original string that generated it.

Describe the solution you'd like
The AST should be updated to include an additional field, raw which includes the original markup that maps onto the node. The compiler should be updated to populate this field.

Describe alternatives you've considered
Something similar can be achieved using the ASTToMarkup function in idyll-ast, however this transformation loses the original formatting and doesn't have a detailed mapping between AST nodes and substrings in the markup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant