Closed k0kubun closed 1 year ago
There's a Haml user impacted by this. Once we merge this, can we cut a new release? If you wish, I can do that myself if you make me a gem owner on rubygems.org as well. Currently, I can only merge PRs and not release them.
@judofyr WDYT about https://github.com/judofyr/temple/pull/138#issuecomment-1255746989? I'd like to release and maintain the optimization filters I authored myself. If you're not comfortable with it, I could separately maintain Haml's original version in the Haml repository as well.
Thank you for the permission!
StringSplitter
splits a string literal%Q(href("#{1 + 1}");)
into%Q(href()
,1 + 1
, and%Q();)
.Because
%Q(
)
was used for quoting the string and the string content also has parenthesis, it results inunterminated string meets end of file (SyntaxError)
.To extract
"href("
safely, we should just use a null character for quoting a string to beeval
ed.