]> git.madduck.net Git - etc/vim.git/blob - tests/data/remove_parens.py

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

fix environment for readthedocs
[etc/vim.git] / tests / data / remove_parens.py
1 print((1))
2 x = (1)
3 x = (1.2)
4 (x) = (3)
5
6
7 def example():
8     return (("xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"))
9
10
11 def example1():
12     return ((1111111111111111111111111111111111111111111111111111111111111111111111111111111111111))
13
14
15 def example1point5():
16     return ((((((1111111111111111111111111111111111111111111111111111111111111111111111111111111111111))))))
17
18
19 def example2():
20     return (("xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"))
21
22
23 def example3():
24     return ((1111111111111111111111111111111111111111111111111111111111111111111111111111111))
25
26
27 def example4():
28     return ((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((True))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))
29
30
31 def example5():
32     return ((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((()))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))
33
34
35 def example6():
36     return ((((((((({a:a for a in [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17]})))))))))
37
38
39 def example7():
40     return ((((((((({a:a for a in [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20000000000000000000]})))))))))
41
42
43 def example8():
44     return (((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((None)))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))
45
46
47 # output
48 print(1)
49 x = 1
50 x = 1.2
51 x = 3
52
53
54 def example():
55     return "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
56
57
58 def example1():
59     return 1111111111111111111111111111111111111111111111111111111111111111111111111111111111111
60
61
62 def example1point5():
63     return 1111111111111111111111111111111111111111111111111111111111111111111111111111111111111
64
65
66 def example2():
67     return (
68         "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
69     )
70
71
72 def example3():
73     return (
74         1111111111111111111111111111111111111111111111111111111111111111111111111111111
75     )
76
77
78 def example4():
79     return True
80
81
82 def example5():
83     return ()
84
85
86 def example6():
87     return {a: a for a in [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17]}
88
89
90 def example7():
91     return {
92         a: a
93         for a in [
94             1,
95             2,
96             3,
97             4,
98             5,
99             6,
100             7,
101             8,
102             9,
103             10,
104             11,
105             12,
106             13,
107             14,
108             15,
109             16,
110             17,
111             18,
112             19,
113             20000000000000000000,
114         ]
115     }
116
117
118 def example8():
119     return None
120