Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
d645f780
Commit
d645f780
authored
Feb 09, 2001
by
Tim Peters
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Whitespace normalization.
parent
639e62a0
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
13 deletions
+11
-13
Lib/test/test_funcattrs.py
Lib/test/test_funcattrs.py
+3
-4
Lib/test/test_grammar.py
Lib/test/test_grammar.py
+1
-1
Lib/test/test_new.py
Lib/test/test_new.py
+2
-2
Lib/test/test_scope.py
Lib/test/test_scope.py
+5
-6
No files found.
Lib/test/test_funcattrs.py
View file @
d645f780
...
...
@@ -156,13 +156,13 @@ else: raise TestFailed
del
another
.
func_defaults
def
foo
():
pass
pass
def
bar
():
pass
pass
def
temp
():
print
1
print
1
if
foo
==
bar
:
raise
TestFailed
...
...
@@ -172,4 +172,3 @@ d[foo] = 1
foo
.
func_code
=
temp
.
func_code
d
[
foo
]
Lib/test/test_grammar.py
View file @
d645f780
...
...
@@ -367,7 +367,7 @@ while not msg:
finally
:
msg
=
"continue + try/finally ok"
print
msg
print
'return_stmt'
# 'return' [testlist]
def
g1
():
return
def
g2
():
return
1
...
...
Lib/test/test_new.py
View file @
d645f780
...
...
@@ -66,10 +66,10 @@ verify(g['c'] == 3,
# bogus test of new.code()
print
'new.code()'
d
=
new
.
code
(
3
,
3
,
3
,
3
,
codestr
,
(),
(),
(),
d
=
new
.
code
(
3
,
3
,
3
,
3
,
codestr
,
(),
(),
(),
"<string>"
,
"<name>"
,
1
,
""
,
(),
())
# test backwards-compatibility version with no freevars or cellvars
d
=
new
.
code
(
3
,
3
,
3
,
3
,
codestr
,
(),
(),
(),
d
=
new
.
code
(
3
,
3
,
3
,
3
,
codestr
,
(),
(),
(),
"<string>"
,
"<name>"
,
1
,
""
)
if
verbose
:
print
d
Lib/test/test_scope.py
View file @
d645f780
...
...
@@ -105,14 +105,14 @@ verify(test_func(5) == 47)
print
"8. mixed freevars and cellvars"
def
identity
(
x
):
return
x
return
x
def
f
(
x
,
y
,
z
):
def
g
(
a
,
b
,
c
):
a
=
a
+
x
# 3
def
h
():
# z * (4 + 9)
# 3 * 13
# z * (4 + 9)
# 3 * 13
return
identity
(
z
*
(
b
+
y
))
y
=
c
+
z
# 9
return
h
...
...
@@ -120,7 +120,7 @@ def f(x, y, z):
g
=
f
(
1
,
2
,
3
)
h
=
g
(
2
,
4
,
6
)
verify
(
h
()
==
39
)
verify
(
h
()
==
39
)
print
"9. free variable in method"
...
...
@@ -206,7 +206,7 @@ test2 = \
"""
# check_syntax(test2)
# XXX could allow this for exec with const argument, but what's the point
# XXX could allow this for exec with const argument, but what's the point
test3
=
\
"""def error(y):
exec "a = 1"
...
...
@@ -275,4 +275,3 @@ except UnboundLocalError:
pass
else
:
raise
TestFailed
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment