ID:2109783
 
BYOND Version:510.1346
Operating System:Linux
Web Browser:Chrome 51.0.2704.103
Applies to:Dream Maker
Status: Open

Issue hasn't been assigned a status value.
Descriptive Problem Summary:
"[]" compiles, despite making no sense since you can't pass a non-literal string to text().

Numbered Steps to Reproduce Problem:
1. Put "[]" in your code.
2. Stare at DM.

Code Snippet (if applicable) to Reproduce Problem:
/world/New()
var/s = "[]"
for(var/i = 1 to length(s))
world.log << text2ascii(s, i) // 255, 2


Expected Results:
"[]" would not compile outside of a text() call.

Actual Results:
"[]" compiled.

Does the problem occur:
Every time? Or how often? Every time.
In other games? Yes.
In other user accounts? Unknown.
On other computers? Unknown.

When does the problem NOT occur? Always.

Did the problem NOT occur in any earlier versions? If so, what was the last version that worked? Unknown

Workarounds: Don't put "[]" in your code?


Side note: json_decode() handles empty strings strangely; it runtimes with "Unknown value: x", where x is 0 for "", 2 for "[]", 4 for "[][]", etc.