Skip to content

Commit 9fd139a

Browse files
committed
changes from other branches
1 parent 8a1fd7e commit 9fd139a

File tree

6 files changed

+18
-15
lines changed

6 files changed

+18
-15
lines changed

test/stdlib/2.6-exclude.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ SKIP_TESTS=(
1818

1919
[test_cd.py]=1 # i# No module cl
2020
[test_cl.py]=1 # it fails on its own
21+
[test_cmath.py]=pytest
2122
[test_codecmaps_cn.py]=1 # it fails on its own
2223
[test_codecmaps_jp.py]=1 # it fails on its own
2324
[test_codecmaps_kr.py]=1 # it fails on its own

test/stdlib/3.2-exclude.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
SKIP_TESTS=(
22
[test_descr.py]=1 # FIXME: Works on c90ff51?
33

4+
[test_cmath.py]=1 # FIXME
5+
# AssertionError: rect1000: rect(complex(0.0, 0.0))
6+
# Expected: complex(0.0, 0.0)
7+
# Received: complex(0.0, -1.0)
8+
# Received value insufficiently close to expected value.
9+
10+
411
[test_cmd_line.py]=1
512
[test_collections.py]=1
613
[test_concurrent_futures.py]=1 # too long to run over 46 seconds by itself

test/stdlib/3.3-exclude.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ SKIP_TESTS=(
1111
[test_itertools.py]=1
1212

1313
[test_buffer.py]=1 # FIXME: Works on c90ff51
14-
[test_cmath.py]=1 # FIXME: Works on c90ff51
14+
[test_cmath.py]=pytest
1515

1616
[test_atexit.py]=1 # The atexit test starting at 3.3 looks for specific comments in error lines
1717

uncompyle6/semantics/make_function2.py

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2015-2021 by Rocky Bernstein
1+
# Copyright (c) 2015-2021 2024 by Rocky Bernstein
22
# Copyright (c) 2000-2002 by hartmut Goebel <[email protected]>
33
#
44
# This program is free software: you can redistribute it and/or modify
@@ -17,20 +17,17 @@
1717
All the crazy things we have to do to handle Python functions in Python before 3.0.
1818
The saga of changes continues in 3.0 and above and in other files.
1919
"""
20+
from xdis import code_has_star_arg, code_has_star_star_arg, iscode
21+
2022
from uncompyle6.scanner import Code
21-
from uncompyle6.semantics.parser_error import ParserError
22-
from uncompyle6.parser import ParserError as ParserError2
2323
from uncompyle6.semantics.helper import (
24-
print_docstring,
2524
find_all_globals,
2625
find_globals_and_nonlocals,
2726
find_none,
27+
print_docstring,
2828
)
29-
from xdis import iscode, code_has_star_arg, code_has_star_star_arg
30-
31-
from itertools import zip_longest
29+
from uncompyle6.semantics.parser_error import ParserError
3230

33-
from uncompyle6.show import maybe_show_tree_param_default
3431

3532
def make_function2(self, node, is_lambda, nested=1, code_node=None):
3633
"""
@@ -40,8 +37,8 @@ def make_function2(self, node, is_lambda, nested=1, code_node=None):
4037

4138
def build_param(ast, name, default):
4239
"""build parameters:
43-
- handle defaults
44-
- handle format tuple parameters
40+
- handle defaults
41+
- handle format tuple parameters
4542
"""
4643
# if formal parameter is a tuple, the paramater name
4744
# starts with a dot (eg. '.1', '.2')
@@ -52,7 +49,6 @@ def build_param(ast, name, default):
5249

5350
if default:
5451
value = self.traverse(default, indent="")
55-
maybe_show_tree_param_default(self.showast, name, value)
5652
result = "%s=%s" % (name, value)
5753
if result[-2:] == "= ": # default was 'LOAD_CONST None'
5854
result += "None"
@@ -199,5 +195,5 @@ def build_param(ast, name, default):
199195
ast, code.co_name, code._customize, is_lambda=is_lambda, returnNone=rn
200196
)
201197

202-
code._tokens = None # save memory
198+
code._tokens = None # save memory
203199
code._customize = None # save memory

uncompyle6/semantics/make_function3.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,6 @@ def build_param(ast, name, default, annotation=None):
337337
- handle format tuple parameters
338338
"""
339339
value = self.traverse(default, indent="")
340-
maybe_show_tree_param_default(self.showast, name, value)
341340
if annotation:
342341
result = "%s: %s=%s" % (name, annotation, value)
343342
else:

uncompyle6/semantics/n_actions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@ def n_const_list(self, node: SyntaxTree):
278278
elif elem.optype == "const" and not isinstance(elem.attr, str):
279279
value = elem.attr
280280
else:
281-
value = "%s" % repr(elem.pattr)
281+
value = "%s" % repr(elem.attr)
282282
else:
283283
assert elem.kind == "ADD_VALUE_VAR"
284284
value = "%s" % elem.pattr

0 commit comments

Comments
 (0)