Now str array don't take ' on both side when creating the array,
otherwise I compare Bob with 'Bob' and it don't work
This commit is contained in:
Adrien Bouvais 2025-02-12 14:53:39 +01:00
parent 3e234396bf
commit 84f5749aa2

View File

@ -246,7 +246,9 @@ pub fn parseConditionValue(
token.* = self.toker.next();
} else first = false;
if (token.tag == .string_literal) array.append(self.toker.getTokenSlice(token.*)) catch return ZipponError.MemoryError;
if (token.tag == .string_literal) array.append(
self.toker.getTokenSlice(token.*)[1 .. (token.loc.end - token.loc.start) - 1],
) catch return ZipponError.MemoryError;
if (token.tag == .string_literal or token.tag == .comma) continue;
if (token.tag == .r_bracket) break;
return printError(