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

Report all stacktraces in verbose mode (#3938)
[etc/vim.git] / tests / data / cases / pep_654.py
1 # flags: --minimum-version=3.11
2 try:
3     raise OSError("blah")
4 except* ExceptionGroup as e:
5     pass
6
7
8 try:
9     async with trio.open_nursery() as nursery:
10         # Make two concurrent calls to child()
11         nursery.start_soon(child)
12         nursery.start_soon(child)
13 except* ValueError:
14     pass
15
16 try:
17     try:
18         raise ValueError(42)
19     except:
20         try:
21             raise TypeError(int)
22         except* Exception:
23             pass
24         1 / 0
25 except Exception as e:
26     exc = e
27
28 try:
29     try:
30         raise FalsyEG("eg", [TypeError(1), ValueError(2)])
31     except* TypeError as e:
32         tes = e
33         raise
34     except* ValueError as e:
35         ves = e
36         pass
37 except Exception as e:
38     exc = e
39
40 try:
41     try:
42         raise orig
43     except* (TypeError, ValueError) as e:
44         raise SyntaxError(3) from e
45 except BaseException as e:
46     exc = e
47
48 try:
49     try:
50         raise orig
51     except* OSError as e:
52         raise TypeError(3) from e
53 except ExceptionGroup as e:
54     exc = e