1 parent adccafb commit b9c4783Copy full SHA for b9c4783
1 file changed
py/lexer.c
@@ -430,7 +430,8 @@ STATIC void mp_lexer_next_token_into(mp_lexer_t *lex, bool first_token) {
430
vstr_add_char(&lex->vstr, '\\');
431
} else {
432
switch (c) {
433
- case MP_LEXER_EOF: break; // TODO a proper error message?
+ // note: "c" can never be MP_LEXER_EOF because next_char
434
+ // always inserts a newline at the end of the input stream
435
case '\n': c = MP_LEXER_EOF; break; // backslash escape the newline, just ignore it
436
case '\\': break;
437
case '\'': break;
0 commit comments