diff options
author | Florent Xicluna <florent.xicluna@gmail.com> | 2014-03-23 18:37:35 +0100 |
---|---|---|
committer | Florent Xicluna <florent.xicluna@gmail.com> | 2014-03-23 18:37:35 +0100 |
commit | 5731082d257c6743225f4be3628082c50e7dc2ed (patch) | |
tree | 4e2796166d419b61f76d8ec4cee2c409467b54fd /testsuite/E12not.py | |
parent | 68d72a5dd747e1cd6fee9f02b417a70f4d9ff7ca (diff) | |
download | pep8-5731082d257c6743225f4be3628082c50e7dc2ed.tar.gz |
Fix a false positive E124 for hanging indent: issue #254
Diffstat (limited to 'testsuite/E12not.py')
-rw-r--r-- | testsuite/E12not.py | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/testsuite/E12not.py b/testsuite/E12not.py index 655dd6b..a2f72ce 100644 --- a/testsuite/E12not.py +++ b/testsuite/E12not.py @@ -588,3 +588,32 @@ bar( 1).zap( 2) # +if True: + + def example_issue254(): + return [node.copy( + ( + replacement + # First, look at all the node's current children. + for child in node.children + # Replace them. + for replacement in replace(child) + ), + dict(name=token.undefined) + )] + + +def valid_example(): + return [node.copy(properties=dict( + (key, val if val is not None else token.undefined) + for key, val in node.items() + ))] + + +def other_example(): + return [node.copy(properties=dict( + (key, val if val is not None else token.undefined) + for key, val in node.items() + ))] + +# |