New submission from Stefan Krah: IMO the string should start at lineno=1, col_offset=0.
$ ./python Python 3.6.0a0 (default:02b81a82a57d, Jul 12 2015, 20:33:44) [GCC 4.8.4] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import ast >>> a = ast.parse('''"""xxx ... yyy ... zzz"""''') >>> ast.dump(a, include_attributes=True) "Module(body=[Expr(value=Str(s='xxx\\nyyy\\nzzz', lineno=3, col_offset=-1), lineno=3, col_offset=-1)])" ---------- messages: 246665 nosy: skrah priority: normal severity: normal status: open title: Parser: broken line numbers for triple-quoted strings _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue24623> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com