提交 279244f4 编写于 作者: C Cyrus Najmabadi

Add comment.

上级 89b7b8c8
......@@ -1424,7 +1424,11 @@ private RegexPrimaryExpressionNode ParseSingleCharacterClassComponent(bool isFir
return ParseEscape(backslashToken, allowTriviaAfterEnd: false);
case '-':
// trivia is not allowed anywhere in a character class
// trivia is not allowed anywhere in a character class.
// We just let the basic consumption code pull out a token for us, we then
// convert that to text since we treat all characters after the - as text no
// matter what.
return new RegexSimpleEscapeNode(
backslashToken, ConsumeCurrentToken(allowTrivia: false).With(kind: RegexKind.TextToken));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册