-
Notifications
You must be signed in to change notification settings - Fork 20
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
Propagate comments from parser to generated rust code #66
Comments
This might be really tricky especially when we start optimizing constraint expressions and proving a more module way of describing complex constraints. |
Makes sense. Maybe we can limit the type of comments that get propagated? For example comments for things like constant definitions should be easy to propagate. Or if there are general comments pertaining to a whole section. If we go with this kind of restrictive kind of comments, maybe we can have a specialized syntax for comments that will get propagated and we can restrict where in the AIR file they can be used while parsing? |
Yes, I think we can come up with some good approaches here - but I'd wait until we have much more of the language implemented before tackling this (probably after we have support for spreading constraint descriptions over multiple modules/files). |
Another option for this specific issue is to limit the scope of the issue to just preserve the comments in the parser for now (what @grjte originally suggested). |
Currently comments written in the AirScript file are lost after parsing. We should preserve the comments and output them at the relevant places in the generated rust code.
Originally posted by @grjte in #4 (comment)
The text was updated successfully, but these errors were encountered: