I'm using Prep's output (mostly so that it's in ANF) in my full
compilation pipeline, so ideally I would save Prep'd Core in my
.hi-equivalents so that I don't have to rerun Prep on them every time
I use them.
I'll get back to you with some concrete examples of `OtherCon []` vs.
meaningful unfoldings next week.
Merging with my other question about shadowing problems with
`toIface*`, in summary it seems that what I really should be doing, is
compiling up to Tidy, taking the `CoreBinding`s from there and using
`toIfaceBinding` on them to save the definitions.
On Sat, Apr 2, 2022 at 12:53 AM Simon Peyton Jones
<
simon.pe...@gmail.com> wrote:
>
> I don't think any top-level Ids should have OtherCon [] unfoldings? If they do, can you give a repro case? OtherCon [] unfoldings usually mean "I know this variable is evaluated, but I don't know what its value is. E.g
> data T = MkT !a !a
> f (MkT x y) = ...
>
> here x and y have OtherCon [] unfoldings. They are definitely not bottom!
>
> You may want stronger invariants on the output of CorePrep than we have hitherto sought. Can you explain what they are? And why you want the output of CorePrep not CoreTidy?
>
> Thanks
>
> Simon
>> _______________________________________________
>> ghc-devs mailing list
>>
ghc-...@haskell.org
>>
http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs
>
> _______________________________________________
> ghc-devs mailing list
>
ghc-...@haskell.org
>
http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs