StackoverflowException when formatted long triple-quoted strings #1837
Closed
Description
NOTE 1: I cannot use the online tool to report this bug, since it requires a lot of code and the attempt to submit to GitHub is refused because the querystring is too long. Instead, I have created a repro here
NOTE 2: I have a fix for this, which I'll PR later. I just wanted an issue for reference
Code
See gist
Result
A 500
error. When I run locally, it's due to a StackoverflowException
. I assume the same is true when running the online tool, though the underlying error is understandably hidden from the client.
Problem description
Long triple-quoted strings cause a StackoverflowException
within the code that parses interpolated strings, since it has recursive logic that is not tail-call recursive.