Ticket #1903: test.2.pir

File test.2.pir, 1.4 KB (added by plobsing, 4 years ago)

PIR resulting from compiling test.winxed

Line 
1# Begin generated code
2
3.namespace [ 'A' ]
4
5.sub 'a' :method
6
7.annotate 'file', 'test.winxed'
8.annotate 'line', 2
9# Body
10# {
11# predefined say
12.annotate 'line', 3
13say "a"
14# predefined Error
15.annotate 'line', 4
16root_new $P1, ['parrot';'Exception']
17$P1['message'] = "erra"
18throw $P1
19.annotate 'line', 5
20.return(0)
21# }
22.annotate 'line', 6
23
24.end # a
25
26.sub Winxed_class_init :anon :load :init
27newclass $P0, [ 'A' ]
28.end
29.namespace [ ]
30
31.sub 'b'
32
33.annotate 'line', 9
34# Body
35# {
36# predefined say
37.annotate 'line', 10
38say "b"
39# predefined Error
40.annotate 'line', 11
41root_new $P1, ['parrot';'Exception']
42$P1['message'] = "errb"
43throw $P1
44.annotate 'line', 12
45.return(0)
46# }
47.annotate 'line', 13
48
49.end # b
50
51
52.sub 'main' :main
53.param pmc __ARG_1
54
55.annotate 'line', 15
56# Body
57# {
58.annotate 'line', 16
59# try: create handler
60new $P2, 'ExceptionHandler'
61set_label $P2, __label_0
62push_eh $P2
63# try: begin
64# {
65.annotate 'line', 17
66$P3 = __ARG_1[1]
67if_null $P3, __label_2
68unless $P3 goto __label_2
69.annotate 'line', 18
70new $P4, [ 'A' ]
71.tailcall $P4.'a'()
72goto __label_3
73__label_2: # else
74.annotate 'line', 20
75.tailcall 'b'()
76__label_3: # endif
77# }
78# try: end
79pop_eh
80goto __label_1
81.annotate 'line', 16
82# catch
83__label_0:
84.get_results($P1)
85finalize $P1
86pop_eh
87# {
88# predefined say
89.annotate 'line', 22
90say "caught exception"
91# }
92# catch end
93__label_1:
94# }
95.annotate 'line', 24
96
97.end # main
98
99# End generated code