summaryrefslogtreecommitdiff
path: root/testsuite/tests/simplCore/should_compile/T21848.stderr
blob: 2afb4fdb1728108a74697522b114d25977a1055d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442

==================== Specialise ====================
Result size of Specialise
  = {terms: 262, types: 169, coercions: 3, joins: 0/2}

-- RHS size: {terms: 2, types: 1, coercions: 0, joins: 0/0}
$cdummy_a14o :: Int -> ()
[LclId,
 Arity=1,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True,
         Guidance=ALWAYS_IF(arity=1,unsat_ok=True,boring_ok=True)}]
$cdummy_a14o = \ _ [Occ=Dead] -> GHC.Tuple.()

-- RHS size: {terms: 2, types: 1, coercions: 0, joins: 0/0}
$cop_a146 :: Int -> Int
[LclId,
 Arity=1,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True,
         Guidance=ALWAYS_IF(arity=1,unsat_ok=True,boring_ok=True)}]
$cop_a146 = \ (x_aB5 :: Int) -> x_aB5

Rec {
-- RHS size: {terms: 36, types: 18, coercions: 0, joins: 0/0}
$swombat_s1fp :: Int -> Bool -> String
[LclId, Arity=2]
$swombat_s1fp
  = \ (a_aB9 :: Int) (b_aBa :: Bool) ->
      case GHC.Classes.gtInt a_aB9 (GHC.Types.I# 0#) of {
        False ->
          GHC.Base.augment
            @Char
            (\ (@b_a15V)
               (c_a15W [OS=OneShot] :: Char -> b_a15V -> b_a15V)
               (n_a15X [OS=OneShot] :: b_a15V) ->
               GHC.Base.foldr
                 @Char
                 @b_a15V
                 c_a15W
                 n_a15X
                 (case a_aB9 of { GHC.Types.I# n_a162 ->
                  GHC.Show.itos n_a162 (GHC.Types.[] @Char)
                  }))
            (wombat @Bool GHC.Show.$fShowBool a_aB9 b_aBa);
        True ->
          wombat
            @Bool
            GHC.Show.$fShowBool
            (case a_aB9 of { GHC.Types.I# x_a17e ->
             GHC.Types.I# (GHC.Prim.-# x_a17e 1#)
             })
            b_aBa
      }

-- RHS size: {terms: 38, types: 21, coercions: 0, joins: 0/0}
wombat [Occ=LoopBreaker] :: forall b. Show b => Int -> b -> String
[LclIdX,
 Arity=3,
 Unf=Unf{Src=<vanilla>, TopLvl=True, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [0 40 0] 261 40},
 RULES: "SPEC wombat @Bool"
            forall ($dShow_s1fo :: Show Bool).
              wombat @Bool $dShow_s1fo
              = $swombat_s1fp]
wombat
  = \ (@b_a13z)
      ($dShow_a13A :: Show b_a13z)
      (a_aB9 :: Int)
      (b_aBa :: b_a13z) ->
      case GHC.Classes.gtInt a_aB9 (GHC.Types.I# 0#) of {
        False ->
          GHC.Base.augment
            @Char
            (\ (@b_a15V)
               (c_a15W [OS=OneShot] :: Char -> b_a15V -> b_a15V)
               (n_a15X [OS=OneShot] :: b_a15V) ->
               GHC.Base.foldr
                 @Char
                 @b_a15V
                 c_a15W
                 n_a15X
                 (case a_aB9 of { GHC.Types.I# n_a162 ->
                  GHC.Show.itos n_a162 (GHC.Types.[] @Char)
                  }))
            (wombat @b_a13z $dShow_a13A a_aB9 b_aBa);
        True ->
          wombat
            @b_a13z
            $dShow_a13A
            (case a_aB9 of { GHC.Types.I# x_a17e ->
             GHC.Types.I# (GHC.Prim.-# x_a17e 1#)
             })
            b_aBa
      }
end Rec }

-- RHS size: {terms: 3, types: 1, coercions: 0, joins: 0/0}
T21848.$fCInt [InlPrag=CONLIKE] :: C Int
[LclIdX[DFunId],
 Unf=DFun: \ -> T21848.C:C TYPE: Int wombat $cdummy_a14o]
T21848.$fCInt = T21848.C:C @Int wombat $cdummy_a14o

-- RHS size: {terms: 3, types: 1, coercions: 0, joins: 0/0}
T21848.$fDInt [InlPrag=CONLIKE] :: D Int
[LclIdX[DFunId],
 Unf=DFun: \ -> T21848.C:D TYPE: Int T21848.$fCInt $cop_a146]
T21848.$fDInt = T21848.C:D @Int T21848.$fCInt $cop_a146

-- RHS size: {terms: 27, types: 21, coercions: 0, joins: 0/1}
$sf_s1fn [InlPrag=[0]] :: Int -> Bool -> [Char]
[LclId, Arity=2]
$sf_s1fn
  = \ (eta_B0 :: Int) (eta_B1 :: Bool) ->
      let {
        $dC_s1fm :: C Int
        [LclId,
         Unf=Unf{Src=<vanilla>, TopLvl=False, Value=False, ConLike=True,
                 WorkFree=True, Expandable=True,
                 Guidance=ALWAYS_IF(arity=0,unsat_ok=True,boring_ok=True)}]
        $dC_s1fm = T21848.$fCInt } in
      GHC.Base.augment
        @Char
        (\ (@b_a15V)
           (c_a15W [OS=OneShot] :: Char -> b_a15V -> b_a15V)
           (n_a15X [OS=OneShot] :: b_a15V) ->
           GHC.Base.foldr
             @Char
             @b_a15V
             c_a15W
             n_a15X
             (wombat @Bool GHC.Show.$fShowBool eta_B0 eta_B1))
        (GHC.Base.augment
           @Char
           (\ (@b_a15V)
              (c_a15W [OS=OneShot] :: Char -> b_a15V -> b_a15V)
              (n_a15X [OS=OneShot] :: b_a15V) ->
              GHC.CString.unpackFoldrCString# @b_a15V "!"# c_a15W n_a15X)
           (wombat @Bool GHC.Show.$fShowBool eta_B0 eta_B1))

-- RHS size: {terms: 34, types: 30, coercions: 0, joins: 0/1}
f [InlPrag=INLINABLE[0]]
  :: forall a b. (D a, Show b) => a -> b -> String
[LclId,
 Arity=4,
 Unf=Unf{Src=InlineStable, TopLvl=True, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [30 0 0 0] 210 0
         Tmpl= \ (@a_a12O)
                 (@b_a12P)
                 ($dD_a12Q [Occ=OnceL1] :: D a_a12O)
                 ($dShow_a12R :: Show b_a12P)
                 (eta_B0 :: a_a12O)
                 (eta_B1 :: b_a12P) ->
                 let {
                   $dC_a14v :: C a_a12O
                   [LclId,
                    Unf=Unf{Src=<vanilla>, TopLvl=False, Value=False, ConLike=False,
                            WorkFree=False, Expandable=True, Guidance=IF_ARGS [] 20 0}]
                   $dC_a14v = T21848.$p1D @a_a12O $dD_a12Q } in
                 ++
                   @Char
                   (meth @a_a12O $dC_a14v @b_a12P $dShow_a12R eta_B0 eta_B1)
                   (GHC.CString.unpackAppendCString#
                      "!"# (meth @a_a12O $dC_a14v @b_a12P $dShow_a12R eta_B0 eta_B1))},
 RULES: "SPEC f @Int @Bool" [0]
            forall ($dD_s1fj :: D Int) ($dShow_s1fk :: Show Bool).
              f @Int @Bool $dD_s1fj $dShow_s1fk
              = $sf_s1fn]
f = \ (@a_a12O)
      (@b_a12P)
      ($dD_a12Q :: D a_a12O)
      ($dShow_a12R :: Show b_a12P)
      (eta_B0 :: a_a12O)
      (eta_B1 :: b_a12P) ->
      let {
        $dC_s1fi :: C a_a12O
        [LclId,
         Unf=Unf{Src=<vanilla>, TopLvl=False, Value=False, ConLike=False,
                 WorkFree=False, Expandable=True, Guidance=IF_ARGS [] 20 0}]
        $dC_s1fi = T21848.$p1D @a_a12O $dD_a12Q } in
      GHC.Base.augment
        @Char
        (\ (@b_a15V)
           (c_a15W [OS=OneShot] :: Char -> b_a15V -> b_a15V)
           (n_a15X [OS=OneShot] :: b_a15V) ->
           GHC.Base.foldr
             @Char
             @b_a15V
             c_a15W
             n_a15X
             (meth @a_a12O $dC_s1fi @b_a12P $dShow_a12R eta_B0 eta_B1))
        (GHC.Base.augment
           @Char
           (\ (@b_a15V)
              (c_a15W [OS=OneShot] :: Char -> b_a15V -> b_a15V)
              (n_a15X [OS=OneShot] :: b_a15V) ->
              GHC.CString.unpackFoldrCString# @b_a15V "!"# c_a15W n_a15X)
           (meth @a_a12O $dC_s1fi @b_a12P $dShow_a12R eta_B0 eta_B1))

-- RHS size: {terms: 6, types: 2, coercions: 0, joins: 0/0}
main_s1f2 :: String
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=False, ConLike=False,
         WorkFree=False, Expandable=False, Guidance=IF_ARGS [] 60 0}]
main_s1f2
  = f @Int
      @Bool
      T21848.$fDInt
      GHC.Show.$fShowBool
      (GHC.Types.I# 42#)
      GHC.Types.True

-- RHS size: {terms: 4, types: 0, coercions: 0, joins: 0/0}
main_s1f3
  :: GHC.Prim.State# GHC.Prim.RealWorld
     -> (# GHC.Prim.State# GHC.Prim.RealWorld, () #)
[LclId,
 Arity=1,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 40 60}]
main_s1f3
  = GHC.IO.Handle.Text.hPutStr2
      GHC.IO.Handle.FD.stdout main_s1f2 GHC.Types.True

-- RHS size: {terms: 1, types: 0, coercions: 3, joins: 0/0}
main :: IO ()
[LclIdX,
 Arity=1,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True,
         Guidance=ALWAYS_IF(arity=0,unsat_ok=True,boring_ok=True)}]
main
  = main_s1f3
    `cast` (Sym (GHC.Types.N:IO[0] <()>_R)
            :: (GHC.Prim.State# GHC.Prim.RealWorld
                -> (# GHC.Prim.State# GHC.Prim.RealWorld, () #))
               ~R# IO ())

-- RHS size: {terms: 1, types: 0, coercions: 0, joins: 0/0}
$trModule_s1f4 :: GHC.Prim.Addr#
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 20 0}]
$trModule_s1f4 = "main"#

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$trModule_s1f5 :: GHC.Types.TrName
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$trModule_s1f5 = GHC.Types.TrNameS $trModule_s1f4

-- RHS size: {terms: 1, types: 0, coercions: 0, joins: 0/0}
$trModule_s1f6 :: GHC.Prim.Addr#
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 30 0}]
$trModule_s1f6 = "T21848"#

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$trModule_s1f7 :: GHC.Types.TrName
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$trModule_s1f7 = GHC.Types.TrNameS $trModule_s1f6

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
T21848.$trModule :: GHC.Types.Module
[LclIdX,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
T21848.$trModule = GHC.Types.Module $trModule_s1f5 $trModule_s1f7

-- RHS size: {terms: 3, types: 1, coercions: 0, joins: 0/0}
$krep_a14Q [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14Q
  = GHC.Types.KindRepTyConApp
      GHC.Types.$tcConstraint (GHC.Types.[] @GHC.Types.KindRep)

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
$krep_a14P [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14P = GHC.Types.KindRepFun GHC.Types.krep$* $krep_a14Q

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$krep_s1f8 :: Int
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_s1f8 = GHC.Types.I# 0#

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$krep_a14T [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=False, ConLike=True,
         WorkFree=False, Expandable=True, Guidance=IF_ARGS [] 20 0}]
$krep_a14T = GHC.Types.$WKindRepVar $krep_s1f8

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
$krep_a14V [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14V = GHC.Types.KindRepFun $krep_a14T $krep_a14T

-- RHS size: {terms: 1, types: 0, coercions: 0, joins: 0/0}
$tcC_s1f9 :: GHC.Prim.Addr#
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 20 0}]
$tcC_s1f9 = "C"#

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$tcC_s1fa :: GHC.Types.TrName
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$tcC_s1fa = GHC.Types.TrNameS $tcC_s1f9

-- RHS size: {terms: 7, types: 0, coercions: 0, joins: 0/0}
T21848.$tcC :: GHC.Types.TyCon
[LclIdX,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
T21848.$tcC
  = GHC.Types.TyCon
      14679919086118427567##64
      12559744112860329810##64
      T21848.$trModule
      $tcC_s1fa
      0#
      $krep_a14P

-- RHS size: {terms: 3, types: 2, coercions: 0, joins: 0/0}
$krep_s1fb :: [GHC.Types.KindRep]
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_s1fb
  = GHC.Types.:
      @GHC.Types.KindRep $krep_a14T (GHC.Types.[] @GHC.Types.KindRep)

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
$krep_a14S [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14S = GHC.Types.KindRepTyConApp T21848.$tcC $krep_s1fb

-- RHS size: {terms: 1, types: 0, coercions: 0, joins: 0/0}
$tcD_s1fc :: GHC.Prim.Addr#
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 20 0}]
$tcD_s1fc = "D"#

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$tcD_s1fd :: GHC.Types.TrName
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$tcD_s1fd = GHC.Types.TrNameS $tcD_s1fc

-- RHS size: {terms: 7, types: 0, coercions: 0, joins: 0/0}
T21848.$tcD :: GHC.Types.TyCon
[LclIdX,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
T21848.$tcD
  = GHC.Types.TyCon
      2028775029841869083##64
      18183109077030380353##64
      T21848.$trModule
      $tcD_s1fd
      0#
      $krep_a14P

-- RHS size: {terms: 3, types: 2, coercions: 0, joins: 0/0}
$krep_s1fe :: [GHC.Types.KindRep]
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_s1fe
  = GHC.Types.:
      @GHC.Types.KindRep $krep_a14T (GHC.Types.[] @GHC.Types.KindRep)

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
$krep_a14W [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14W = GHC.Types.KindRepTyConApp T21848.$tcD $krep_s1fe

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
$krep_a14U [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14U = GHC.Types.KindRepFun $krep_a14V $krep_a14W

-- RHS size: {terms: 3, types: 0, coercions: 0, joins: 0/0}
$krep_a14R [InlPrag=[~]] :: GHC.Types.KindRep
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$krep_a14R = GHC.Types.KindRepFun $krep_a14S $krep_a14U

-- RHS size: {terms: 1, types: 0, coercions: 0, joins: 0/0}
$tc'C:D_s1ff :: GHC.Prim.Addr#
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 20 0}]
$tc'C:D_s1ff = "'C:D"#

-- RHS size: {terms: 2, types: 0, coercions: 0, joins: 0/0}
$tc'C:D_s1fg :: GHC.Types.TrName
[LclId,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
$tc'C:D_s1fg = GHC.Types.TrNameS $tc'C:D_s1ff

-- RHS size: {terms: 7, types: 0, coercions: 0, joins: 0/0}
T21848.$tc'C:D :: GHC.Types.TyCon
[LclIdX,
 Unf=Unf{Src=<vanilla>, TopLvl=False, Value=True, ConLike=True,
         WorkFree=True, Expandable=True, Guidance=IF_ARGS [] 10 10}]
T21848.$tc'C:D
  = GHC.Types.TyCon
      4845813539547459579##64
      7908713917114703782##64
      T21848.$trModule
      $tc'C:D_s1fg
      1#
      $krep_a14R