rescript-lang.org icon indicating copy to clipboard operation
rescript-lang.org copied to clipboard

Playground: incomplete hex escape in string triggers an infinite loop

Open k4b7 opened this issue 4 years ago • 1 comments

Typing the following code into the playground will trigger an infinite loop which stalls the browser:

let a = "\x

The same happens if you type an empty string first and then add the \x inside of it. I tried reproducing this with bsc.exe but it exits with an appropriate syntax error in both situations so this appears to be playground specific. I paused the debugger and saw that it's trying to get the char code of some string at a very large index.

Capture d’écran, le 2021-12-04 à 00 15 44

k4b7 avatar Dec 04 '21 05:12 k4b7

that's probably something for @bobzhang Maybe that's an issue with the jsoo'ed output?

ryyppy avatar Jan 19 '22 10:01 ryyppy

not reproducible anymore

fhammerschmidt avatar Mar 09 '24 23:03 fhammerschmidt