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
The recent Crystal 0.32.0 release includes the new String.interpolation as an alternative codegen for what used to be based on String.build (see #8400).
This is causing issues for me on heredocs with interpolation:
bug =<<-ENDx#{2}xx... 300 more lines with just "x"...xxEND
I noticed from reading the parser that heredocs are represented as a StringInterpolation nodes with each line as a individual string in this case. I believe there should be an AST transformation on top of StringInterpolation that will merge any two successive string literals into one, avoiding the issue if I'm just writing a long heredoc. Is this the correct approach to fix this?
The text was updated successfully, but these errors were encountered:
The recent Crystal 0.32.0 release includes the new
String.interpolation
as an alternative codegen for what used to be based onString.build
(see #8400).This is causing issues for me on heredocs with interpolation:
Fails to compile with:
I noticed from reading the parser that heredocs are represented as a
StringInterpolation
nodes with each line as a individual string in this case. I believe there should be an AST transformation on top ofStringInterpolation
that will merge any two successive string literals into one, avoiding the issue if I'm just writing a long heredoc. Is this the correct approach to fix this?The text was updated successfully, but these errors were encountered: