]> Git — Sourcephile - haskell/symantic-parser.git/blob - test/Golden/Splice/G9.expected.txt
fix: use a global polyfix for defLet and defRef
[haskell/symantic-parser.git] / test / Golden / Splice / G9.expected.txt
1 \(input_0 :: inp_6989586621679059048) ->
2 let !(#
3 init_1,
4 readMore_2,
5 readNext_3
6 #) =
7 let _ = "cursorOf"
8 in let next_4
9 ( t_5@( Data.Text.Internal.Text
10 arr_6
11 off_7
12 unconsumed_8
13 )
14 ) =
15 let !( Data.Text.Unsafe.Iter
16 c_9
17 d_10
18 ) = Data.Text.Unsafe.iter t_5 0
19 in (#
20 c_9,
21 Data.Text.Internal.Text arr_6 (off_7 GHC.Num.+ d_10) (unconsumed_8 GHC.Num.- d_10)
22 #)
23 more_11
24 ( Data.Text.Internal.Text
25 _
26 _
27 unconsumed_12
28 ) = unconsumed_12 GHC.Classes.> 0
29 in (#
30 input_0,
31 more_11,
32 next_4
33 #)
34 in let finalRet_13 = \_farInp_14 _farExp_15 v_16 _inp_17 -> Data.Either.Right v_16
35 in let finalRaise_18 ::
36 forall b_19.
37 Symantic.Parser.Machine.Generate.Catcher
38 inp_6989586621679059048
39 b_19 = \_failInp_20 (!farInp_21) (!farExp_22) ->
40 Data.Either.Left
41 Symantic.Parser.Machine.Generate.ParsingErrorStandard
42 { Symantic.Parser.Machine.Generate.parsingErrorOffset = Symantic.Parser.Machine.Input.offset farInp_21,
43 Symantic.Parser.Machine.Generate.parsingErrorUnexpected =
44 if readMore_2 farInp_21
45 then
46 GHC.Maybe.Just
47 ( let (#
48 c_23,
49 _
50 #) = readNext_3 farInp_21
51 in c_23
52 )
53 else GHC.Maybe.Nothing,
54 Symantic.Parser.Machine.Generate.parsingErrorExpecting = Data.Set.Internal.fromList farExp_22
55 }
56 in let
57 in let _ = "catchException lbl=fail"
58 in let catchHandler_24 (!failInp_25) (!farInp_26) (!farExp_27) =
59 let _ = "catchException.ko lbl=fail"
60 in if ( \( Data.Text.Internal.Text
61 _
62 i_28
63 _
64 )
65 ( Data.Text.Internal.Text
66 _
67 j_29
68 _
69 ) -> i_28 GHC.Classes.== j_29
70 )
71 init_1
72 failInp_25
73 then
74 let _ = "choicesBranch.then"
75 in let (#
76 farInp_30,
77 farExp_31
78 #) = case (GHC.Classes.compare `Data.Function.on` Symantic.Parser.Machine.Input.offset) farInp_26 failInp_25 of
79 GHC.Types.LT ->
80 (#
81 failInp_25,
82 [Symantic.Parser.Grammar.Combinators.ErrorItemEnd]
83 #)
84 GHC.Types.EQ ->
85 (#
86 farInp_26,
87 farExp_27 GHC.Base.<> [Symantic.Parser.Grammar.Combinators.ErrorItemEnd]
88 #)
89 GHC.Types.GT ->
90 (#
91 farInp_26,
92 farExp_27
93 #)
94 in finalRaise_18 failInp_25 farInp_30 farExp_31
95 else
96 let _ = "choicesBranch.else"
97 in let (#
98 farInp_32,
99 farExp_33
100 #) = case (GHC.Classes.compare `Data.Function.on` Symantic.Parser.Machine.Input.offset) farInp_26 failInp_25 of
101 GHC.Types.LT ->
102 (#
103 failInp_25,
104 []
105 #)
106 GHC.Types.EQ ->
107 (#
108 farInp_26,
109 farExp_27 GHC.Base.<> []
110 #)
111 GHC.Types.GT ->
112 (#
113 farInp_26,
114 farExp_27
115 #)
116 in finalRaise_18 failInp_25 farInp_32 farExp_33
117 in let _ = "catchException lbl=fail"
118 in let catchHandler_34 (!failInp_35) (!farInp_36) (!farExp_37) =
119 let _ = "catchException.ko lbl=fail"
120 in let _ = "resume"
121 in finalRet_13
122 farInp_36
123 farExp_37
124 ( let _ = "resume.genCode"
125 in GHC.Tuple . ()
126 )
127 init_1
128 in let readFail_38 = catchHandler_34
129 in if readMore_2 init_1
130 then
131 let !(#
132 c_39,
133 cs_40
134 #) = readNext_3 init_1
135 in if (\x_41 -> GHC.Types.True) c_39
136 then
137 let (#
138 farInp_42,
139 farExp_43
140 #) = case (GHC.Classes.compare `Data.Function.on` Symantic.Parser.Machine.Input.offset) init_1 init_1 of
141 GHC.Types.LT ->
142 (#
143 init_1,
144 []
145 #)
146 GHC.Types.EQ ->
147 (#
148 init_1,
149 GHC.Types . [] GHC.Base.<> []
150 #)
151 GHC.Types.GT ->
152 (#
153 init_1,
154 GHC.Types . []
155 #)
156 in catchHandler_24 init_1 farInp_42 farExp_43
157 else
158 let _ = "checkToken.else"
159 in let (#
160 farInp_44,
161 farExp_45
162 #) = case (GHC.Classes.compare `Data.Function.on` Symantic.Parser.Machine.Input.offset) init_1 init_1 of
163 GHC.Types.LT ->
164 (#
165 init_1,
166 []
167 #)
168 GHC.Types.EQ ->
169 (#
170 init_1,
171 GHC.Types . [] GHC.Base.<> []
172 #)
173 GHC.Types.GT ->
174 (#
175 init_1,
176 GHC.Types . []
177 #)
178 in readFail_38 init_1 farInp_44 farExp_45
179 else
180 let _ = "checkHorizon.else"
181 in let (#
182 farInp_46,
183 farExp_47
184 #) = case (GHC.Classes.compare `Data.Function.on` Symantic.Parser.Machine.Input.offset) init_1 init_1 of
185 GHC.Types.LT ->
186 (#
187 init_1,
188 [Symantic.Parser.Grammar.Combinators.ErrorItemHorizon 1]
189 #)
190 GHC.Types.EQ ->
191 (#
192 init_1,
193 GHC.Types . [] GHC.Base.<> [Symantic.Parser.Grammar.Combinators.ErrorItemHorizon 1]
194 #)
195 GHC.Types.GT ->
196 (#
197 init_1,
198 GHC.Types . []
199 #)
200 in readFail_38 init_1 farInp_46 farExp_47