Skip to content

Commit b108c77

Browse files
committed
Line wrap news blurb and correctly indent if conditions
1 parent 9df9bb0 commit b108c77

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
Fix a crash in :mod:`tokenize` when a mismatched closing bracket follows the opening brace of an f-string or t-string replacement field, as in ``f'{]a'``. It now raises the same "unmatched" error as the parser.
1+
Fix a crash in :mod:`tokenize` when a mismatched closing bracket follows the
2+
opening brace of an f-string or t-string replacement field, as in ``f'{]a'``.
3+
It now raises the same "unmatched" error as the parser.

‎Parser/lexer/lexer.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1294,8 +1294,8 @@ tok_get_normal_mode(struct tok_state *tok, tokenizer_mode* current_tok, struct t
12941294
tok->level--;
12951295
int opening = tok->parenstack[tok->level];
12961296
if (!((opening == '(' && c == ')') ||
1297-
(opening == '[' && c == ']') ||
1298-
(opening == '{' && c == '}'))) {
1297+
(opening == '[' && c == ']') ||
1298+
(opening == '{' && c == '}'))) {
12991299
/* If the opening bracket belongs to an f-string's expression
13001300
part (e.g. f"{)}") and the closing bracket is an arbitrary
13011301
nested expression, then instead of matching a different

0 commit comments

Comments
 (0)