Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Lib/test/test_fstring.py
Original file line number Diff line number Diff line change
Expand Up @@ -1370,7 +1370,7 @@ def test_conversions(self):
for conv in ' s', ' s ':
self.assertAllRaise(SyntaxError,
"f-string: conversion type must come right after the"
" exclamanation mark",
" exclamation mark",
["f'{3!" + conv + "}'"])

self.assertAllRaise(SyntaxError,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix typo in the f-string conversion type error ("exclamanation" -> "exclamation").
2 changes: 1 addition & 1 deletion Parser/action_helpers.c
Original file line number Diff line number Diff line change
Expand Up @@ -955,7 +955,7 @@ _PyPegen_check_fstring_conversion(Parser *p, Token* conv_token, expr_ty conv)
if (conv_token->lineno != conv->lineno || conv_token->end_col_offset != conv->col_offset) {
return RAISE_SYNTAX_ERROR_KNOWN_RANGE(
conv_token, conv,
"f-string: conversion type must come right after the exclamanation mark"
"f-string: conversion type must come right after the exclamation mark"
);
}
return result_token_with_metadata(p, conv, conv_token->metadata);
Expand Down
Loading