mirror of
https://github.com/python/cpython.git
synced 2025-07-29 22:24:49 +00:00
Fix SF bug #1519018: 'as' is now validated properly in import statements
This commit is contained in:
parent
b6b175229b
commit
fb48afa708
3 changed files with 18 additions and 1 deletions
|
@ -238,6 +238,8 @@ if 1:
|
|||
succeed = [
|
||||
'import sys',
|
||||
'import os, sys',
|
||||
'import os as bar',
|
||||
'import os.path as bar',
|
||||
'from __future__ import nested_scopes, generators',
|
||||
'from __future__ import (nested_scopes,\ngenerators)',
|
||||
'from __future__ import (nested_scopes,\ngenerators,)',
|
||||
|
@ -257,6 +259,8 @@ if 1:
|
|||
'import (sys',
|
||||
'import sys)',
|
||||
'import (os,)',
|
||||
'import os As bar',
|
||||
'import os.path a bar',
|
||||
'from (sys) import stdin',
|
||||
'from __future__ import (nested_scopes',
|
||||
'from __future__ import nested_scopes)',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue