Log In  

I'm trying to make a string with a certain combination of characters which is causing compiler errors. I want to make a string with the following characters:

pstvx14.,?/="+

With the escape character for the quote mark, it should be:

str="pstvx14.,?/=\"+"

If you copy just that line into PICO-8 and try and run it, you'll get the following error:

syntax error line 1
<eof>
<name> expected near ','

If you delete the . then the , then the ? you'll get a different error each time (unexpected symbol, syntax error). If you then delete the / it's fine, so the following string is ok:

str="pstvx14=\"+"

Different combinations of punctuation will give varying errors. It seems like this is a parser error?

There's also a highlighting error when you have a string containing just the backslash character:

str="\\"
--this should be grey not blue
--the blue stops here:" grey

This code compiles and runs fine because it's valid syntax, but the editor doesn't highlight it correctly.

P#18799 2016-02-13 13:17 ( Edited 2016-02-13 18:22)

And it counts the tokens in this case! Reported this two weeks ago.

P#18800 2016-02-13 13:22 ( Edited 2016-02-13 18:22)

[Please log in to post a comment]

Follow Lexaloffle:        
Generated 2020-04-10 02:55 | 0.008s | 2097k | Q:12