INADA Naoki <songofaca...@gmail.com> added the comment: I tried this patch:
diff --git a/Python/ast.c b/Python/ast.c index e2092f0f85..93be2bc839 100644 --- a/Python/ast.c +++ b/Python/ast.c @@ -3537,9 +3537,9 @@ docstring_from_stmts(asdl_seq *stmts) if (s->kind == Expr_kind && s->v.Expr.value->kind == Str_kind) { string doc = s->v.Expr.value->v.Str.s; /* not very efficient, but simple */ - memmove(&asdl_seq_GET(stmts, 0), &asdl_seq_GET(stmts, 1), - (stmts->size - 1) * sizeof(void*)); - stmts->size--; + //memmove(&asdl_seq_GET(stmts, 0), &asdl_seq_GET(stmts, 1), + // (stmts->size - 1) * sizeof(void*)); + //stmts->size--; return doc; } } But I got "SyntaxError: from __future__ imports must occur at the beginning of the file". docstring is very special while it looks like just a single string literal statement... ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue32911> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com