|
@@ -324,7 +324,13 @@ public ref struct Lexer
|
|
|
if (c is '\\')
|
|
if (c is '\\')
|
|
|
{
|
|
{
|
|
|
Advance(1);
|
|
Advance(1);
|
|
|
|
|
+
|
|
|
if (span.Length <= offset) break;
|
|
if (span.Length <= offset) break;
|
|
|
|
|
+ if (span[offset] == '\r')
|
|
|
|
|
+ {
|
|
|
|
|
+ if (span.Length<=offset +1) continue;
|
|
|
|
|
+ if (span[offset+1] == '\n')Advance(1);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
else if (c == quote)
|
|
else if (c == quote)
|
|
|
{
|
|
{
|
|
@@ -530,8 +536,8 @@ public ref struct Lexer
|
|
|
static bool IsIdentifier(char c)
|
|
static bool IsIdentifier(char c)
|
|
|
{
|
|
{
|
|
|
return c == '_' ||
|
|
return c == '_' ||
|
|
|
- ('A' <= c && c <= 'Z') ||
|
|
|
|
|
- ('a' <= c && c <= 'z') ||
|
|
|
|
|
- StringHelper.IsNumber(c);
|
|
|
|
|
|
|
+ ('A' <= c && c <= 'Z') ||
|
|
|
|
|
+ ('a' <= c && c <= 'z') ||
|
|
|
|
|
+ StringHelper.IsNumber(c);
|
|
|
}
|
|
}
|
|
|
-}
|
|
|
|
|
|
|
+}
|