-
Notifications
You must be signed in to change notification settings - Fork 210
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
1.22: union construction seems not to be normalised #915
Comments
Also, I should note that this worked in 1.21 (or, well, something with very much the same shape did), so either it's a regression or needs a heads-up in the changelog. |
You're right, it appears that |
Yeah, the bug here is that https://github.com/dhall-lang/dhall-lang/blob/master/standard/%CE%B2-normalization.md#unions In other words, the new-style union literal of the form |
Fix is up here: #918 |
I discovered it wasn't working right in dhall-lang#926. The underlying bug is very similar to dhall-lang#915, and in fact this builds on the fix for that in dhall-lang#918. It looks like the single-constructor case is a different underlying bug that I don't understand just yet, so let's tackle that separately.
The underlying bug is very similar to dhall-lang#915, and in fact this builds on the fix for that in dhall-lang#918. Closes dhall-lang#926.
The underlying bug is very similar to dhall-lang#915, and in fact this builds on the fix for that in dhall-lang#918. Closes dhall-lang#926.
Running this program against current HEAD (44a2750)
results in this output
By copying in the definition of
union
,unionType
, etc, and sticking in some judicious debugging prints, the source of the failure's narrowed to this statement:dhall-haskell/dhall/src/Dhall.hs
Line 1538 in 44a2750
The expression isn't a
UnionLit
, but rather anApp
of the field of the union and then the empty record. It looks very much like something's not being normalised properly - or perhaps this is expected in 1.22, andunion
needs to learn how to massage the expression into the form that it needs?The text was updated successfully, but these errors were encountered: