diff options
author | Victor Stinner <vstinner@redhat.com> | 2018-04-30 21:51:02 (GMT) |
---|---|---|
committer | Ćukasz Langa <lukasz@langa.pl> | 2018-04-30 21:51:02 (GMT) |
commit | fb7e7992beec7f76cc2db77ab6ce1e86446bfccf (patch) | |
tree | 60f7280ffa657033d2e488e41512287ddc00c072 /Python/ast.c | |
parent | 5a49ca61d2f00941c304b2390af8a927bf1c4a77 (diff) | |
download | cpython-fb7e7992beec7f76cc2db77ab6ce1e86446bfccf.zip cpython-fb7e7992beec7f76cc2db77ab6ce1e86446bfccf.tar.gz cpython-fb7e7992beec7f76cc2db77ab6ce1e86446bfccf.tar.bz2 |
bpo-30465: Fix C downcast warning on Windows in ast.c (#6593)
ast.c: fstring_fix_node_location() downcasts a pointer difference to
a C int. Replace int with Py_ssize_t to fix the compiler warning.
Diffstat (limited to 'Python/ast.c')
-rw-r--r-- | Python/ast.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/ast.c b/Python/ast.c index e2092f0..0d692ff 100644 --- a/Python/ast.c +++ b/Python/ast.c @@ -4313,7 +4313,7 @@ fstring_fix_node_location(const node *parent, node *n, char *expr_str) break; start--; } - cols += substr - start; + cols += (int)(substr - start); /* Fix lineno in mulitline strings. */ while ((substr = strchr(substr + 1, '\n'))) lines--; |