-
Notifications
You must be signed in to change notification settings - Fork 46
fix(wit-grammar) handle inline comments #1117
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
base: main
Are you sure you want to change the base?
Conversation
|
getting some strange logic for newline separations, @Xophmeister any thoughts? |
The preserved blank line on L4 makes sense. You have the blank in the input and you have On L20-21 in the input (L18-19 in the output): you have a (
[
(export_item)
(func_item)
(import_item)
(include_item)
(interface_item)
(package_decl)
(resource_item)
(type_item)
(resource_method)
(since_gate)
(deprecated_gate)
(unstable_gate)
] @append_spaced_softline
.
[
(block_comment)
(line_comment)
]* @do_nothing
)I guess those (body
.
"{" @append_hardline @append_indent_start @prepend_space
_
"}" @append_hardline @prepend_hardline @prepend_indent_end
.
) @append_hardlineI'm pretty sure the two |
Handle inline comments and trailing commas in WIT
Resolves #XXX
References #YYY
Depends on #ZZZ
Description
[PR Description]
Checklist
Checklist before merging, wherever relevant:
CHANGELOG.mdupdatedREADME.md, etc.) up-to-date