GHC issues
https://gitlab.haskell.org/ghc/ghc/-/issues
2019-07-07T18:41:42Z
https://gitlab.haskell.org/ghc/ghc/-/issues/9140
Unboxed tuples fails in GHCi (7.8.2)
2019-07-07T18:41:42Z
Ömer Sinan Ağacan
Unboxed tuples fails in GHCi (7.8.2)
Creating an unboxed tuple in GHCi causes panic:
```
➜ ~ ghci -XUnboxedTuples
GHCi, version 7.8.2: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done...
Creating an unboxed tuple in GHCi causes panic:
```
➜ ~ ghci -XUnboxedTuples
GHCi, version 7.8.2: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
ghci> let a = (# 1 #)
ghc: panic! (the 'impossible' happened)
(GHC version 7.8.2 for x86_64-unknown-linux):
dsLet: unlifted
AbsBinds [a{tv auv} [tv]] [$dNum_auw{v} [lid]]
{Exports: [a{v asV} [lid] <= a{v asY} [lid]
/\(@ a{tv auy} [tv]).
\($dNum_auz{v} [lid] :: base:GHC.Num.Num{tc 2b} a{tv auy} [tv]).
let {EvBinds{$dNum_auC{v} [lid] = $dNum_auz{v} [lid]}}
(<>) @ a{tv auy} [tv] $dNum_auC{v} [lid]]
Exported types: a{v asV} [lid]
:: forall a{tv auv} [tv].
base:GHC.Num.Num{tc 2b} a{tv auv} [tv] =>
(# a{tv auv} [tv] #)
[LclId, Str=DmdType]
Binds: {<interactive>:2:5-15}
a{v asY} [lid] :: (# a{tv auv} [tv] #)
[LclId, Str=DmdType]
a{v asY}
= {<interactive>:2:9-15}
(# 1 ((base:GHC.Num.fromInteger{v 02A}) @ a{tv auv} [tv]
$dNum_au8{v} [lid]
1) #)
<>
Evidence: EvBinds{$dNum_au8{v} [lid] = $dNum_auw{v} [lid]}}
base:GHC.Base.returnIO{v 0z} [gid]
@ [()]
(ghc-prim:GHC.Types.:{(w) v 65} [gid[DataCon]]
@ ()
(ghc-prim:GHC.Prim.unsafeCoerce#{(w) v 0u} [gid]
@ (forall a{tv auv} [tv].
base:GHC.Num.Num{tc 2b} a{tv auv} [tv] =>
(# a{tv auv} [tv] #))
@ ()
a{v asV} [lid])
(ghc-prim:GHC.Types.[]{(w) v 6n} [gid[DataCon]] @ ()))
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
ghci> let a = (# 1, 2 #)
ghc: panic! (the 'impossible' happened)
(GHC version 7.8.2 for x86_64-unknown-linux):
dsLet: unlifted
AbsBinds [a{tv auW} [tv], a{tv auX} [tv]] [$dNum_auY{v} [lid],
$dNum_auZ{v} [lid]]
{Exports: [a{v auK} [lid] <= a{v auN} [lid]
/\(@ a{tv av1} [tv]).
/\(@ a{tv av2} [tv]).
\($dNum_av3{v} [lid] :: base:GHC.Num.Num{tc 2b} a{tv av2} [tv]).
\($dNum_av4{v} [lid] :: base:GHC.Num.Num{tc 2b} a{tv av1} [tv]).
let {EvBinds{$dNum_av8{v} [lid] = $dNum_av3{v} [lid]
$dNum_av9{v} [lid] = $dNum_av4{v} [lid]}}
(<>) @ a{tv av1} [tv] @ a{tv av2} [tv] $dNum_av8{v} [lid]
$dNum_av9{v} [lid]]
Exported types: a{v auK} [lid]
:: forall a{tv auW} [tv] a{tv auX} [tv].
(base:GHC.Num.Num{tc 2b} a{tv auX} [tv],
base:GHC.Num.Num{tc 2b} a{tv auW} [tv]) =>
(# a{tv auW} [tv], a{tv auX} [tv] #)
[LclId, Str=DmdType]
Binds: {<interactive>:3:5-18}
a{v auN} [lid] :: (# a{tv auW} [tv], a{tv auX} [tv] #)
[LclId, Str=DmdType]
a{v auN}
= {<interactive>:3:9-18}
(# 1 ((base:GHC.Num.fromInteger{v 02A}) @ a{tv auW} [tv]
$dNum_auR{v} [lid]
1),
2 ((base:GHC.Num.fromInteger{v 02A}) @ a{tv auX} [tv]
$dNum_auT{v} [lid]
2) #)
<>
Evidence: EvBinds{$dNum_auR{v} [lid] = $dNum_auZ{v} [lid]
$dNum_auT{v} [lid] = $dNum_auY{v} [lid]}}
base:GHC.Base.returnIO{v 0z} [gid]
@ [()]
(ghc-prim:GHC.Types.:{(w) v 65} [gid[DataCon]]
@ ()
(ghc-prim:GHC.Prim.unsafeCoerce#{(w) v 0u} [gid]
@ (forall a{tv auW} [tv] a{tv auX} [tv].
(base:GHC.Num.Num{tc 2b} a{tv auX} [tv],
base:GHC.Num.Num{tc 2b} a{tv auW} [tv]) =>
(# a{tv auW} [tv], a{tv auX} [tv] #))
@ ()
a{v auK} [lid])
(ghc-prim:GHC.Types.[]{(w) v 6n} [gid[DataCon]] @ ()))
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
ghci>
```
<details><summary>Trac metadata</summary>
| Trac field | Value |
| ---------------------- | ------------ |
| Version | 7.8.2 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | GHCi |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | hvr |
| Operating system | |
| Architecture | |
</details>
<!-- {"blocked_by":[],"summary":"Unboxed tuples fails in GHCi (7.8.2)","status":"New","operating_system":"","component":"GHCi","related":[],"milestone":"","resolution":"Unresolved","owner":{"tag":"Unowned"},"version":"7.8.2","keywords":[],"differentials":[],"test_case":"","architecture":"","cc":["hvr"],"type":"Bug","description":"Creating an unboxed tuple in GHCi causes panic:\r\n\r\n{{{\r\n➜ ~ ghci -XUnboxedTuples\r\nGHCi, version 7.8.2: http://www.haskell.org/ghc/ :? for help\r\nLoading package ghc-prim ... linking ... done.\r\nLoading package integer-gmp ... linking ... done.\r\nLoading package base ... linking ... done.\r\nghci> let a = (# 1 #)\r\nghc: panic! (the 'impossible' happened)\r\n (GHC version 7.8.2 for x86_64-unknown-linux):\r\n dsLet: unlifted\r\n AbsBinds [a{tv auv} [tv]] [$dNum_auw{v} [lid]]\r\n {Exports: [a{v asV} [lid] <= a{v asY} [lid]\r\n /\\(@ a{tv auy} [tv]).\r\n \\($dNum_auz{v} [lid] :: base:GHC.Num.Num{tc 2b} a{tv auy} [tv]).\r\n let {EvBinds{$dNum_auC{v} [lid] = $dNum_auz{v} [lid]}}\r\n (<>) @ a{tv auy} [tv] $dNum_auC{v} [lid]]\r\n Exported types: a{v asV} [lid]\r\n :: forall a{tv auv} [tv].\r\n base:GHC.Num.Num{tc 2b} a{tv auv} [tv] =>\r\n (# a{tv auv} [tv] #)\r\n [LclId, Str=DmdType]\r\n Binds: {<interactive>:2:5-15}\r\n a{v asY} [lid] :: (# a{tv auv} [tv] #)\r\n [LclId, Str=DmdType]\r\n a{v asY}\r\n = {<interactive>:2:9-15}\r\n (# 1 ((base:GHC.Num.fromInteger{v 02A}) @ a{tv auv} [tv]\r\n $dNum_au8{v} [lid]\r\n 1) #)\r\n <>\r\n Evidence: EvBinds{$dNum_au8{v} [lid] = $dNum_auw{v} [lid]}}\r\n base:GHC.Base.returnIO{v 0z} [gid]\r\n @ [()]\r\n (ghc-prim:GHC.Types.:{(w) v 65} [gid[DataCon]]\r\n @ ()\r\n (ghc-prim:GHC.Prim.unsafeCoerce#{(w) v 0u} [gid]\r\n @ (forall a{tv auv} [tv].\r\n base:GHC.Num.Num{tc 2b} a{tv auv} [tv] =>\r\n (# a{tv auv} [tv] #))\r\n @ ()\r\n a{v asV} [lid])\r\n (ghc-prim:GHC.Types.[]{(w) v 6n} [gid[DataCon]] @ ()))\r\n\r\nPlease report this as a GHC bug: http://www.haskell.org/ghc/reportabug\r\n\r\nghci> let a = (# 1, 2 #)\r\nghc: panic! (the 'impossible' happened)\r\n (GHC version 7.8.2 for x86_64-unknown-linux):\r\n dsLet: unlifted\r\n AbsBinds [a{tv auW} [tv], a{tv auX} [tv]] [$dNum_auY{v} [lid],\r\n $dNum_auZ{v} [lid]]\r\n {Exports: [a{v auK} [lid] <= a{v auN} [lid]\r\n /\\(@ a{tv av1} [tv]).\r\n /\\(@ a{tv av2} [tv]).\r\n \\($dNum_av3{v} [lid] :: base:GHC.Num.Num{tc 2b} a{tv av2} [tv]).\r\n \\($dNum_av4{v} [lid] :: base:GHC.Num.Num{tc 2b} a{tv av1} [tv]).\r\n let {EvBinds{$dNum_av8{v} [lid] = $dNum_av3{v} [lid]\r\n $dNum_av9{v} [lid] = $dNum_av4{v} [lid]}}\r\n (<>) @ a{tv av1} [tv] @ a{tv av2} [tv] $dNum_av8{v} [lid]\r\n $dNum_av9{v} [lid]]\r\n Exported types: a{v auK} [lid]\r\n :: forall a{tv auW} [tv] a{tv auX} [tv].\r\n (base:GHC.Num.Num{tc 2b} a{tv auX} [tv],\r\n base:GHC.Num.Num{tc 2b} a{tv auW} [tv]) =>\r\n (# a{tv auW} [tv], a{tv auX} [tv] #)\r\n [LclId, Str=DmdType]\r\n Binds: {<interactive>:3:5-18}\r\n a{v auN} [lid] :: (# a{tv auW} [tv], a{tv auX} [tv] #)\r\n [LclId, Str=DmdType]\r\n a{v auN}\r\n = {<interactive>:3:9-18}\r\n (# 1 ((base:GHC.Num.fromInteger{v 02A}) @ a{tv auW} [tv]\r\n $dNum_auR{v} [lid]\r\n 1), \r\n 2 ((base:GHC.Num.fromInteger{v 02A}) @ a{tv auX} [tv]\r\n $dNum_auT{v} [lid]\r\n 2) #)\r\n <>\r\n Evidence: EvBinds{$dNum_auR{v} [lid] = $dNum_auZ{v} [lid]\r\n $dNum_auT{v} [lid] = $dNum_auY{v} [lid]}}\r\n base:GHC.Base.returnIO{v 0z} [gid]\r\n @ [()]\r\n (ghc-prim:GHC.Types.:{(w) v 65} [gid[DataCon]]\r\n @ ()\r\n (ghc-prim:GHC.Prim.unsafeCoerce#{(w) v 0u} [gid]\r\n @ (forall a{tv auW} [tv] a{tv auX} [tv].\r\n (base:GHC.Num.Num{tc 2b} a{tv auX} [tv],\r\n base:GHC.Num.Num{tc 2b} a{tv auW} [tv]) =>\r\n (# a{tv auW} [tv], a{tv auX} [tv] #))\r\n @ ()\r\n a{v auK} [lid])\r\n (ghc-prim:GHC.Types.[]{(w) v 6n} [gid[DataCon]] @ ()))\r\n\r\nPlease report this as a GHC bug: http://www.haskell.org/ghc/reportabug\r\n\r\nghci> \r\n}}}\r\n","type_of_failure":"OtherFailure","blocking":[]} -->
7.10.1
archblob
archblob
https://gitlab.haskell.org/ghc/ghc/-/issues/7730
:info and polykinds
2019-07-07T18:48:23Z
Krzysztof Gogolewski
:info and polykinds
```
ghci -XPolyKinds
Prelude> data A x y
Prelude> :i A
data A k k x y -- Defined at <interactive>:3:6
```
The two `k` might be different. It should be either `A k l x y` or - without kind variables - `A x y`.
<details><summary>Trac m...
```
ghci -XPolyKinds
Prelude> data A x y
Prelude> :i A
data A k k x y -- Defined at <interactive>:3:6
```
The two `k` might be different. It should be either `A k l x y` or - without kind variables - `A x y`.
<details><summary>Trac metadata</summary>
| Trac field | Value |
| ---------------------- | ------------ |
| Version | 7.6.2 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | Compiler |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture | |
</details>
<!-- {"blocked_by":[],"summary":":info and polykinds","status":"New","operating_system":"","component":"Compiler","related":[],"milestone":"","resolution":"Unresolved","owner":{"tag":"Unowned"},"version":"7.6.2","keywords":[],"differentials":[],"test_case":"","architecture":"","cc":[""],"type":"Bug","description":"{{{\r\nghci -XPolyKinds\r\n\r\nPrelude> data A x y\r\nPrelude> :i A\r\ndata A k k x y \t-- Defined at <interactive>:3:6\r\n}}}\r\n\r\nThe two `k` might be different. It should be either {{{A k l x y}}} or - without kind variables - {{{A x y}}}.","type_of_failure":"OtherFailure","blocking":[]} -->
7.10.1
archblob
archblob