Skip to content
Snippets Groups Projects
Forked from Glasgow Haskell Compiler / GHC
Source project has a limited visibility.
  • sheaf's avatar
    34d8bc24
    Fix parsing & printing of unboxed sums · 34d8bc24
    sheaf authored and Marge Bot's avatar Marge Bot committed
    The pretty-printing of partially applied unboxed sums was incorrect,
    as we incorrectly dropped the first half of the arguments, even
    for a partial application such as
    
      (# | #) @IntRep @DoubleRep Int#
    
    which lead to the nonsensical (# DoubleRep | Int# #).
    
    This patch also allows users to write unboxed sum type constructors
    such as
    
      (# | #) :: TYPE r1 -> TYPE r2 -> TYPE (SumRep '[r1,r2]).
    
    Fixes #20858 and #20859.
    34d8bc24
    History
    Fix parsing & printing of unboxed sums
    sheaf authored and Marge Bot's avatar Marge Bot committed
    The pretty-printing of partially applied unboxed sums was incorrect,
    as we incorrectly dropped the first half of the arguments, even
    for a partial application such as
    
      (# | #) @IntRep @DoubleRep Int#
    
    which lead to the nonsensical (# DoubleRep | Int# #).
    
    This patch also allows users to write unboxed sum type constructors
    such as
    
      (# | #) :: TYPE r1 -> TYPE r2 -> TYPE (SumRep '[r1,r2]).
    
    Fixes #20858 and #20859.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.