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

Remove click patch (#3768)
[etc/vim.git] / tests / data / miscellaneous / python2_detection.py
1 # This uses a similar construction to the decorators.py test data file FYI.
2
3 print "hello, world!"
4
5 ###
6
7 exec "print('hello, world!')"
8
9 ###
10
11 def set_position((x, y), value):
12     pass
13
14 ###
15
16 try:
17     pass
18 except Exception, err:
19     pass
20
21 ###
22
23 raise RuntimeError, "I feel like crashing today :p"
24
25 ###
26
27 `wow_these_really_did_exist`
28
29 ###
30
31 10L
32
33 ###
34
35 10l
36
37 ###
38
39 0123
40
41 # output
42
43 print("hello python three!")
44
45 ###
46
47 exec("I'm not sure if you can use exec like this but that's not important here!")
48
49 ###
50
51 try:
52     pass
53 except make_exception(1, 2):
54     pass
55
56 ###
57
58 try:
59     pass
60 except Exception as err:
61     pass
62
63 ###
64
65 raise RuntimeError(make_msg(1, 2))
66
67 ###
68
69 raise RuntimeError("boom!",)
70
71 ###
72
73 def set_position(x, y, value):
74     pass
75
76 ###
77
78 10
79
80 ###
81
82 0
83
84 ###
85
86 000
87
88 ###
89
90 0o12