Skip to content
Snippets Groups Projects
  1. Sep 27, 2023
  2. Sep 26, 2023
  3. Sep 23, 2023
  4. Sep 21, 2023
  5. Sep 19, 2023
    • Matthew Pickering's avatar
      Bump ci-images to use updated version of Alex · 142f8740
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      Fixes #23977
      142f8740
    • glaubitz's avatar
      Re-add unregisterised build support for sparc and sparc64 · 665ca116
      glaubitz authored and Marge Bot's avatar Marge Bot committed
      Closes #23959
      665ca116
    • John Ericson's avatar
      Remove `ghc-cabal` · 35bc506b
      John Ericson authored and Marge Bot's avatar Marge Bot committed
      It is dead code since the Make build system was removed.
      
      I tried to go over every match of `git grep -i ghc-cabal` to find other
      stray bits. Some of those might be workarounds that can be further
      removed.
      35bc506b
    • sheaf's avatar
      Validity: refactor treatment of data families · 1eed645c
      sheaf authored and Marge Bot's avatar Marge Bot committed
      This commit refactors the reporting of unused type variables in type
      and data family instances to be more principled. This avoids ad-hoc
      logic in the treatment of data family instances.
      1eed645c
    • sheaf's avatar
      Unused tyvars in FamInst: only report user tyvars · 28dd52ee
      sheaf authored and Marge Bot's avatar Marge Bot committed
      This commit changes how we perform some validity checking for
      coercion axioms to mirror how we handle default declarations for
      associated type families. This allows us to keep track of whether
      type variables in type and data family instances were user-written
      or not, in order to only report the user-written ones in
      "unused type variable" error messages.
      
      Consider for example:
      
        {-# LANGUAGE PolyKinds #-}
        type family F
        type instance forall a. F = ()
      
      In this case, we get two quantified type variables,
      (k :: Type) and (a :: k); the second being user-written, but the first
      is introduced by the typechecker. We should only report 'a' as being
      unused, as the user has no idea what 'k' is.
      
      Fixes #23734
      28dd52ee
    • sheaf's avatar
      Adjust reporting of unused tyvars in data FamInsts · a525a92a
      sheaf authored and Marge Bot's avatar Marge Bot committed
      This commit adjusts the validity checking of data family
      instances to improve the reporting of unused type variables.
      
      See Note [Out of scope tvs in data family instances] in GHC.Tc.Validity.
      
      The problem was that, in a situation such as
      
        data family D :: Type
        data instance forall (d :: Type). D = MkD
      
      the RHS passed to 'checkFamPatBinders' would be the TyCon app
      
        R:D d
      
      which mentions the type variable 'd' quantified in the user-written
      forall. Thus, when computing the set of unused type variables in
      the RHS of the data family instance, we would find that 'd' is used,
      and report a strange error message that would say that 'd' is not
      bound on the LHS.
      
      To fix this, we special-case the data-family instance case,
      manually extracting all the type variables that appear in the
      arguments of all the data constructores of the data family instance.
      
      Fixes #23778
      a525a92a
Loading