]> git.madduck.net Git - etc/vim.git/blob - tests/data/force_pyi.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:

Strip redundant parentheses from assignment exprs (#1906)
[etc/vim.git] / tests / data / force_pyi.py
1 from typing import Union
2
3 @bird
4 def zoo(): ...
5
6 class A: ...
7 @bar
8 class B:
9     def BMethod(self) -> None: ...
10     @overload
11     def BMethod(self, arg : List[str]) -> None: ...
12
13 class C: ...
14 @hmm
15 class D: ...
16 class E: ...
17
18 @baz
19 def foo() -> None:
20     ...
21
22 class F (A , C): ...
23 def spam() -> None: ...
24
25 @overload
26 def spam(arg: str) -> str: ...
27
28 var  : int = 1
29
30 def eggs() -> Union[str, int]: ...
31
32 # output
33
34 from typing import Union
35
36 @bird
37 def zoo(): ...
38
39 class A: ...
40
41 @bar
42 class B:
43     def BMethod(self) -> None: ...
44     @overload
45     def BMethod(self, arg: List[str]) -> None: ...
46
47 class C: ...
48
49 @hmm
50 class D: ...
51
52 class E: ...
53
54 @baz
55 def foo() -> None: ...
56
57 class F(A, C): ...
58
59 def spam() -> None: ...
60 @overload
61 def spam(arg: str) -> str: ...
62
63 var: int = 1
64
65 def eggs() -> Union[str, int]: ...