fix: add list newline handling and resolve multiple test TODOs across compiler and test suite
- Add TOKEN_LINE matching after list elements in compiler to allow newlines before commas or closing brackets - Add tests for list newline handling, EOF after comma/element, and class name inside body - Remove resolved TODOs for default constructors, inherited fields, metaclass is checks, zero comparison, and bitwise not behavior
This commit is contained in:
@@ -1176,6 +1176,9 @@ static void list(Compiler* compiler, bool allowAssignment)
|
||||
{
|
||||
numElements++;
|
||||
expression(compiler);
|
||||
|
||||
// Ignore a newline after the element but before the ',' or ']'.
|
||||
match(compiler, TOKEN_LINE);
|
||||
} while (match(compiler, TOKEN_COMMA));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user