You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
foo do
bar(
script:"on change put my.value1 into the previous <span/>",
# script: "# on change set (previous <input/>).value and (previous <span/>).innerHTML to my.value1# "
) doendend
But, after format, get following invalid expression.
╰─ $ cat foo.cr |crystal tool format-
foo do
bar(
script:"on change put my.value1 into the previous <span/>"# script: "# on change set (previous <input/>).value and (previous <span/>).innerHTML to my.value1# "
,
) doendend
In foo.cr:6:1
6 | ,
^
Error: expecting token ')', not ','
Thanks
The text was updated successfully, but these errors were encountered:
This looks like two bug: The formatter should not butcher full-line comments in an argument list. But the parser should also be able to read the resulting code. There's nothing wrong with it.
So keeping this issue focussed on the formatter, I created #14616 for the parser bug.
Bug Report
Following is a valid crystal script.
foo.cr
But, after format, get following invalid expression.
Thanks
The text was updated successfully, but these errors were encountered: