Skip to content
Snippets Groups Projects
  1. Jul 21, 2023
    • Finley McIlwaine's avatar
      Insert documentation into parsed signature modules · b444c16f
      Finley McIlwaine authored and Marge Bot's avatar Marge Bot committed
      Causes haddock comments in signature modules to be properly
      inserted into the AST (just as they are for regular modules)
      if the `-haddock` flag is given.
      
      Also adds a test that compares `-ddump-parsed-ast` output
      for a signature module to prevent further regressions.
      
      Fixes #23315
      b444c16f
  2. Jul 19, 2023
  3. Jul 17, 2023
  4. Jul 05, 2023
    • Vladislav Zavialov's avatar
      testsuite: Do not require CUSKs · 679bbc97
      Vladislav Zavialov authored and Marge Bot's avatar Marge Bot committed
      Numerous tests make use of CUSKs (complete user-supplied kinds),
      a legacy feature scheduled for deprecation. In order to proceed
      with the said deprecation, the tests have been updated to use SAKS
      instead (standalone kind signatures).
      
      This also allows us to remove the Haskell2010 language pragmas that
      were added in 115cd3c8 to work around the lack of CUSKs in GHC2021.
      679bbc97
  5. Jun 21, 2023
    • Bartłomiej Cieślar's avatar
      Add support for deprecating exported items (proposal #134) · 711b1d24
      Bartłomiej Cieślar authored and Ben Gamari's avatar Ben Gamari committed
      
      This is an implementation of the deprecated exports proposal #134.
      The proposal introduces an ability to introduce warnings to exports.
      This allows for deprecating a name only when it is exported from a specific
      module, rather than always depreacting its usage. In this example:
      
          module A ({-# DEPRECATED "do not use" #-} x) where
          x = undefined
          ---
          module B where
          import A(x)
      
      `x` will emit a warning when it is explicitly imported.
      
      Like the declaration warnings, export warnings are first accumulated within
      the `Warnings` struct, then passed into the ModIface, from which they are
      then looked up and warned about in the importing module in the `lookup_ie`
      helpers of the `filterImports` function (for the explicitly imported names)
      and in the `addUsedGRE(s)` functions where they warn about regular usages
      of the imported name.
      
      In terms of the AST information, the custom warning is stored in the
      extension field of the variants of the `IE` type (see Trees that Grow for
      more information).
      
      The commit includes a bump to the haddock submodule added in MR #28
      
      Signed-off-by: default avatarBartłomiej Cieślar <bcieslar2001@gmail.com>
      711b1d24
  6. Jun 20, 2023
    • Magnus Viernickel's avatar
      [feat] add a hint to `HasField` error message · 1464a2a8
      Magnus Viernickel authored and Marge Bot's avatar Marge Bot committed
      - add a hint that indicates that the record that the record dot is used
        on might just be missing a field
      - as the intention of the programmer is not entirely clear, it is only
        shown if the type is known
      - This addresses in part issue #22382
      1464a2a8
  7. Jun 07, 2023
    • Vladislav Zavialov's avatar
      Invisible binders in type declarations (#22560) · 4aea0a72
      Vladislav Zavialov authored
      
      This patch implements @k-binders introduced in GHC Proposal #425
      and guarded behind the TypeAbstractions extension:
      
      	type D :: forall k j. k -> j -> Type
      	data D @k @j a b = ...
      	       ^^ ^^
      
      To represent the new syntax, we modify LHsQTyVars as follows:
      
      	-  hsq_explicit :: [LHsTyVarBndr () pass]
      	+  hsq_explicit :: [LHsTyVarBndr (HsBndrVis pass) pass]
      
      HsBndrVis is a new data type that records the distinction between
      type variable binders written with and without the @ sign:
      
      	data HsBndrVis pass
      	  = HsBndrRequired
      	  | HsBndrInvisible (LHsToken "@" pass)
      
      The rest of the patch updates GHC, template-haskell, and haddock
      to handle the new syntax.
      
      Parser:
        The PsErrUnexpectedTypeAppInDecl error message is removed.
        The syntax it used to reject is now permitted.
      
      Renamer:
        The @ sign does not affect the scope of a binder, so the changes to
        the renamer are minimal.  See rnLHsTyVarBndrVisFlag.
      
      Type checker:
        There are three code paths that were updated to deal with the newly
        introduced invisible type variable binders:
      
          1. checking SAKS: see kcCheckDeclHeader_sig, matchUpSigWithDecl
          2. checking CUSK: see kcCheckDeclHeader_cusk
          3. inference: see kcInferDeclHeader, rejectInvisibleBinders
      
        Helper functions bindExplicitTKBndrs_Q_Skol and bindExplicitTKBndrs_Q_Tv
        are generalized to work with HsBndrVis.
      
      Updates the haddock submodule.
      
      Metric Increase:
          MultiLayerModulesTH_OneShot
      
      Co-authored-by: default avatarSimon Peyton Jones <simon.peytonjones@gmail.com>
      4aea0a72
  8. May 27, 2023
    • Alan Zimmerman's avatar
      EPA: Better fix for #22919 · 69fdbece
      Alan Zimmerman authored and Marge Bot's avatar Marge Bot committed
      The original fix for #22919 simply removed the ability to match up
      prior comments with the first declaration in the file.
      
      Restore it, but add a check that the comment is on a single line, by
      ensuring that it comes immediately prior to the next thing (comment or
      start of declaration), and that the token preceding it is not on the
      same line.
      
      closes #22919
      69fdbece
  9. May 25, 2023
  10. May 24, 2023
    • Hai Nguyen Quang's avatar
      Migrate errors in GHC.Tc.Validity · 838aaf4b
      Hai Nguyen Quang authored and Marge Bot's avatar Marge Bot committed
      This patch migrates the error messages in GHC.Tc.Validity to use
      the new diagnostic infrastructure.
      
      It adds the constructors:
      
        - TcRnSimplifiableConstraint
        - TcRnArityMismatch
        - TcRnIllegalInstanceDecl, with sub-datatypes for HasField errors
          and fundep coverage condition errors.
      838aaf4b
  11. May 19, 2023
  12. May 15, 2023
    • sheaf's avatar
      Migrate errors to diagnostics in GHC.Tc.Module · 4d29ecdf
      sheaf authored and Marge Bot's avatar Marge Bot committed
      This commit migrates the errors in GHC.Tc.Module to use the new
      diagnostic infrastructure.
      
      It required a significant overhaul of the compatibility checks between
      an hs-boot or signature module and its implementation; we now use
      a Writer monad to accumulate errors; see the BootMismatch datatype
      in GHC.Tc.Errors.Types, with its panoply of subtypes.
      For the sake of readability, several local functions inside the
      'checkBootTyCon' function were split off into top-level functions.
      
      We split off GHC.Types.HscSource into a "boot or sig" vs "normal hs file"
      datatype, as this mirrors the logic in several other places where we
      want to treat hs-boot and hsig files in a similar fashion.
      
      This commit also refactors the Backpack checks for type synonyms
      implementing abstract data, to correctly reject implementations that
      contain qualified or quantified types (this fixes #23342 and #23344).
      4d29ecdf
  13. May 05, 2023
  14. Apr 26, 2023
  15. Apr 25, 2023
  16. Apr 03, 2023
    • Haskell-mouse's avatar
      Convert diagnostics in GHC.Rename.HsType to proper TcRnMessage · 8b092910
      Haskell-mouse authored and Marge Bot's avatar Marge Bot committed
      I've turned all occurrences of TcRnUnknownMessage in GHC.Rename.HsType
      module into a proper TcRnMessage.
      Instead, these TcRnMessage messages were introduced:
      
      TcRnDataKindsError
      TcRnUnusedQuantifiedTypeVar
      TcRnIllegalKindSignature
      TcRnUnexpectedPatSigType
      TcRnSectionPrecedenceError
      TcRnPrecedenceParsingError
      TcRnIllegalKind
      TcRnNegativeNumTypeLiteral
      TcRnUnexpectedKindVar
      TcRnBindMultipleVariables
      TcRnBindVarAlreadyInScope
      8b092910
  17. Apr 01, 2023
  18. Mar 30, 2023
  19. Mar 29, 2023
    • sheaf's avatar
      Handle records in the renamer · 3f374399
      sheaf authored
      This patch moves the field-based logic for disambiguating record updates
      to the renamer. The type-directed logic, scheduled for removal, remains
      in the typechecker.
      
      To do this properly (and fix the myriad of bugs surrounding the treatment
      of duplicate record fields), we took the following main steps:
      
        1. Create GREInfo, a renamer-level equivalent to TyThing which stores
           information pertinent to the renamer.
           This allows us to uniformly treat imported and local Names in the
           renamer, as described in Note [GREInfo].
      
        2. Remove GreName. Instead of a GlobalRdrElt storing GreNames, which
           distinguished between normal names and field names, we now store
           simple Names in GlobalRdrElt, along with the new GREInfo information
           which allows us to recover the FieldLabel for record fields.
      
        3. Add namespacing for record fields, within the OccNames themselves.
           This allows us to remove the mangling of duplicate field selectors.
      
           This change ensures we don't print mangled names to the user in
           error messages, and allows us to handle duplicate record fields
           in Template Haskell.
      
        4. Move record disambiguation to the renamer, and operate on the
           level of data constructors instead, to handle #21443.
      
           The error message text for ambiguous record updates has also been
           changed to reflect that type-directed disambiguation is on the way
           out.
      
      (3) means that OccEnv is now a bit more complex: we first key on the
      textual name, which gives an inner map keyed on NameSpace:
      
        OccEnv a ~ FastStringEnv (UniqFM NameSpace a)
      
      Note that this change, along with (2), both increase the memory residency
      of GlobalRdrEnv = OccEnv [GlobalRdrElt], which causes a few tests to
      regress somewhat in compile-time allocation.
      
      Even though (3) simplified a lot of code (in particular the treatment of
      field selectors within Template Haskell and in error messages), it came
      with one important wrinkle: in the situation of
      
        -- M.hs-boot
        module M where { data A; foo :: A -> Int }
        -- M.hs
        module M where { data A = MkA { foo :: Int } }
      
      we have that M.hs-boot exports a variable foo, which is supposed to match
      with the record field foo that M exports. To solve this issue, we add a
      new impedance-matching binding to M
      
        foo{var} = foo{fld}
      
      This mimics the logic that existed already for impedance-binding DFunIds,
      but getting it right was a bit tricky.
      See Note [Record field impedance matching] in GHC.Tc.Module.
      
      We also needed to be careful to avoid introducing space leaks in GHCi.
      So we dehydrate the GlobalRdrEnv before storing it anywhere, e.g. in
      ModIface. This means stubbing out all the GREInfo fields, with the
      function forceGlobalRdrEnv.
      When we read it back in, we rehydrate with rehydrateGlobalRdrEnv.
      This robustly avoids any space leaks caused by retaining old type
      environments.
      
      Fixes #13352 #14848 #17381 #17551 #19664 #21443 #21444 #21720 #21898 #21946 #21959 #22125 #22160 #23010 #23062 #23063
      
      Updates haddock submodule
      
      -------------------------
      Metric Increase:
          MultiComponentModules
          MultiLayerModules
          MultiLayerModulesDefsGhci
          MultiLayerModulesNoCode
          T13701
          T14697
          hard_hole_fits
      -------------------------
      3f374399
  20. Mar 24, 2023
    • Adam Gundry's avatar
      Allow WARNING pragmas to be controlled with custom categories · f932c589
      Adam Gundry authored and Marge Bot's avatar Marge Bot committed
      Closes #17209. This implements GHC Proposal 541, allowing a WARNING
      pragma to be annotated with a category like so:
      
          {-# WARNING in "x-partial" head "This function is undefined on empty lists." #-}
      
      The user can then enable, disable and set the severity of such warnings
      using command-line flags `-Wx-partial`, `-Werror=x-partial` and so on.  There
      is a new warning group `-Wextended-warnings` containing all these warnings.
      Warnings without a category are treated as if the category was `deprecations`,
      and are (still) controlled by the flags `-Wdeprecations`
      and `-Wwarnings-deprecations`.
      
      Updates Haddock submodule.
      f932c589
  21. Mar 06, 2023
    • Andrei Borzenkov's avatar
      Convert diagnostics in GHC.Rename.Module to proper TcRnMessage (#20115) · cad5c576
      Andrei Borzenkov authored and Marge Bot's avatar Marge Bot committed
      I've turned almost all occurrences of TcRnUnknownMessage in GHC.Rename.Module
      module into a proper TcRnMessage.
      Instead, these TcRnMessage messages were introduced:
        TcRnIllegalInstanceHeadDecl
        TcRnUnexpectedStandaloneDerivingDecl
        TcRnUnusedVariableInRuleDecl
        TcRnUnexpectedStandaloneKindSig
        TcRnIllegalRuleLhs
        TcRnBadAssocRhs
        TcRnDuplicateRoleAnnot
        TcRnDuplicateKindSig
        TcRnIllegalDerivStrategy
        TcRnIllegalMultipleDerivClauses
        TcRnNoDerivStratSpecified
        TcRnStupidThetaInGadt
        TcRnBadImplicitSplice
        TcRnShadowedTyVarNameInFamResult
        TcRnIncorrectTyVarOnLhsOfInjCond
        TcRnUnknownTyVarsOnRhsOfInjCond
      
      Was introduced one helper type:
        RuleLhsErrReason
      cad5c576
  22. Feb 08, 2023
  23. Jan 28, 2023
    • Andrei Borzenkov's avatar
      Convert diagnostics in GHC.Rename.Bind to proper TcRnMessage (#20115) · 50b1e2e8
      Andrei Borzenkov authored and Marge Bot's avatar Marge Bot committed
      I removed all occurrences of TcRnUnknownMessage in GHC.Rename.Bind
      module. Instead, these TcRnMessage messages were introduced:
        TcRnMultipleFixityDecls
        TcRnIllegalPatternSynonymDecl
        TcRnIllegalClassBiding
        TcRnOrphanCompletePragma
        TcRnEmptyCase
        TcRnNonStdGuards
        TcRnDuplicateSigDecl
        TcRnMisplacedSigDecl
        TcRnUnexpectedDefaultSig
        TcRnBindInBootFile
        TcRnDuplicateMinimalSig
      50b1e2e8
  24. Jan 06, 2023
    • Matthew Pickering's avatar
      Only store Name in FunRhs rather than Id with knot-tied fields · ac39e8e9
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      All the issues here have been caused by #18758.
      The goal of the ticket is to be able to talk about things like
      `LTyClDecl GhcTc`. In the case of HsMatchContext,
      the correct "context" is whatever we want, and in fact storing just a
      `Name` is sufficient and correct context, even if the rest of the AST is
      storing typechecker Ids.
      
      So this reverts (#20415, !5579) which intended to get closed to #18758 but
      didn't really and introduced a few subtle bugs.
      
      Printing of an error message in #22695 would just hang, because we would
      attempt to print the `Id` in debug mode to assertain whether it was
      empty or not. Printing the Name is fine for the error message.
      
      Another consequence is that when `-dppr-debug` was enabled the compiler would
      hang because the debug printing of the Id would try and print fields
      which were not populated yet.
      
      This also led to 32070e6c having to add
      a workaround for the `checkArgs` function which was probably a very
      similar bug to #22695.
      
      Fixes #22695
      ac39e8e9
    • Vladislav Zavialov's avatar
      HsToken in TypeArg (#19623) · 9e077999
      Vladislav Zavialov authored and Marge Bot's avatar Marge Bot committed
      Updates the haddock submodule.
      9e077999
  25. Jan 05, 2023
    • Alan Zimmerman's avatar
      EPA: Do not collect comments from end of file · 22bb8998
      Alan Zimmerman authored and Marge Bot's avatar Marge Bot committed
      In Parser.y semis1 production triggers for the virtual semi at the end
      of the file. This is detected by it being zero length.
      
      In this case, do not extend the span being used to gather comments, so
      any final comments are allocated at the module level instead.
      22bb8998
  26. Dec 23, 2022
  27. Dec 14, 2022
  28. Nov 24, 2022
    • Andrei Borzenkov's avatar
      Convert diagnostics in GHC.Rename.Expr to proper TcRnMessage (#20115) · 86ff1523
      Andrei Borzenkov authored and Marge Bot's avatar Marge Bot committed
      
      Problem: avoid usage of TcRnMessageUnknown
      
      Solution:
      The following `TcRnMessage` messages has been introduced:
        TcRnNoRebindableSyntaxRecordDot
        TcRnNoFieldPunsRecordDot
        TcRnIllegalStaticExpression
        TcRnIllegalStaticFormInSplice
        TcRnListComprehensionDuplicateBinding
        TcRnEmptyStmtsGroup
        TcRnLastStmtNotExpr
        TcRnUnexpectedStatementInContext
        TcRnIllegalTupleSection
        TcRnIllegalImplicitParameterBindings
        TcRnSectionWithoutParentheses
      
      Co-authored-by: sheaf's avatarsheaf <sam.derbyshire@gmail.com>
      86ff1523
  29. Nov 19, 2022
  30. Nov 11, 2022
    • Simon Peyton Jones's avatar
      Type vs Constraint: finally nailed · 778c6adc
      Simon Peyton Jones authored and Simon Peyton Jones's avatar Simon Peyton Jones committed
      This big patch addresses the rats-nest of issues that have plagued
      us for years, about the relationship between Type and Constraint.
      See #11715/#21623.
      
      The main payload of the patch is:
      * To introduce CONSTRAINT :: RuntimeRep -> Type
      * To make TYPE and CONSTRAINT distinct throughout the compiler
      
      Two overview Notes in GHC.Builtin.Types.Prim
      
      * Note [TYPE and CONSTRAINT]
      
      * Note [Type and Constraint are not apart]
        This is the main complication.
      
      The specifics
      
      * New primitive types (GHC.Builtin.Types.Prim)
        - CONSTRAINT
        - ctArrowTyCon (=>)
        - tcArrowTyCon (-=>)
        - ccArrowTyCon (==>)
        - funTyCon     FUN     -- Not new
        See Note [Function type constructors and FunTy]
        and Note [TYPE and CONSTRAINT]
      
      * GHC.Builtin.Types:
        - New type Constraint = CONSTRAINT LiftedRep
        - I also stopped nonEmptyTyCon being built-in; it only needs to be wired-in
      
      * Exploit the fact that Type and Constraint are distinct throughout GHC
        - Get rid of tcView in favour of coreView.
        - Many tcXX functions become XX functions.
          e.g. tcGetCastedTyVar --> getCastedTyVar
      
      * Kill off Note [ForAllTy and typechecker equality], in (old)
        GHC.Tc.Solver.Canonical.  It said that typechecker-equality should ignore
        the specified/inferred distinction when comparein two ForAllTys.  But
        that wsa only weakly supported and (worse) implies that we need a separate
        typechecker equality, different from core equality. No no no.
      
      * GHC.Core.TyCon: kill off FunTyCon in data TyCon.  There was no need for it,
        and anyway now we have four of them!
      
      * GHC.Core.TyCo.Rep: add two FunTyFlags to FunCo
        See Note [FunCo] in that module.
      
      * GHC.Core.Type.  Lots and lots of changes driven by adding CONSTRAINT.
        The key new function is sORTKind_maybe; most other changes are built
        on top of that.
      
        See also `funTyConAppTy_maybe` and `tyConAppFun_maybe`.
      
      * Fix a longstanding bug in GHC.Core.Type.typeKind, and Core Lint, in
        kinding ForAllTys.  See new tules (FORALL1) and (FORALL2) in GHC.Core.Type.
        (The bug was that before (forall (cv::t1 ~# t2). blah), where
        blah::TYPE IntRep, would get kind (TYPE IntRep), but it should be
        (TYPE LiftedRep).  See Note [Kinding rules for types] in GHC.Core.Type.
      
      * GHC.Core.TyCo.Compare is a new module in which we do eqType and cmpType.
        Of course, no tcEqType any more.
      
      * GHC.Core.TyCo.FVs. I moved some free-var-like function into this module:
        tyConsOfType, visVarsOfType, and occCheckExpand.  Refactoring only.
      
      * GHC.Builtin.Types.  Compiletely re-engineer boxingDataCon_maybe to
        have one for each /RuntimeRep/, rather than one for each /Type/.
        This dramatically widens the range of types we can auto-box.
        See Note [Boxing constructors] in GHC.Builtin.Types
        The boxing types themselves are declared in library ghc-prim:GHC.Types.
      
        GHC.Core.Make.  Re-engineer the treatment of "big" tuples (mkBigCoreVarTup
        etc) GHC.Core.Make, so that it auto-boxes unboxed values and (crucially)
        types of kind Constraint. That allows the desugaring for arrows to work;
        it gathers up free variables (including dictionaries) into tuples.
        See  Note [Big tuples] in GHC.Core.Make.
      
        There is still work to do here: #22336. But things are better than
        before.
      
      * GHC.Core.Make.  We need two absent-error Ids, aBSENT_ERROR_ID for types of
        kind Type, and aBSENT_CONSTRAINT_ERROR_ID for vaues of kind Constraint.
        Ditto noInlineId vs noInlieConstraintId in GHC.Types.Id.Make;
        see Note [inlineId magic].
      
      * GHC.Core.TyCo.Rep. Completely refactor the NthCo coercion.  It is now called
        SelCo, and its fields are much more descriptive than the single Int we used to
        have.  A great improvement.  See Note [SelCo] in GHC.Core.TyCo.Rep.
      
      * GHC.Core.RoughMap.roughMatchTyConName.  Collapse TYPE and CONSTRAINT to
        a single TyCon, so that the rough-map does not distinguish them.
      
      * GHC.Core.DataCon
        - Mainly just improve documentation
      
      * Some significant renamings:
        GHC.Core.Multiplicity: Many -->  ManyTy (easier to grep for)
                               One  -->  OneTy
        GHC.Core.TyCo.Rep TyCoBinder      -->   GHC.Core.Var.PiTyBinder
        GHC.Core.Var      TyCoVarBinder   -->   ForAllTyBinder
                          AnonArgFlag     -->   FunTyFlag
                          ArgFlag         -->   ForAllTyFlag
        GHC.Core.TyCon    TyConTyCoBinder --> TyConPiTyBinder
        Many functions are renamed in consequence
        e.g. isinvisibleArgFlag becomes isInvisibleForAllTyFlag, etc
      
      * I refactored FunTyFlag (was AnonArgFlag) into a simple, flat data type
          data FunTyFlag
            = FTF_T_T           -- (->)  Type -> Type
            | FTF_T_C           -- (-=>) Type -> Constraint
            | FTF_C_T           -- (=>)  Constraint -> Type
            | FTF_C_C           -- (==>) Constraint -> Constraint
      
      * GHC.Tc.Errors.Ppr.  Some significant refactoring in the TypeEqMisMatch case
        of pprMismatchMsg.
      
      * I made the tyConUnique field of TyCon strict, because I
        saw code with lots of silly eval's.  That revealed that
        GHC.Settings.Constants.mAX_SUM_SIZE can only be 63, because
        we pack the sum tag into a 6-bit field.  (Lurking bug squashed.)
      
      Fixes
      * #21530
      
      Updates haddock submodule slightly.
      
      Performance changes
      ~~~~~~~~~~~~~~~~~~~
      I was worried that compile times would get worse, but after
      some careful profiling we are down to a geometric mean 0.1%
      increase in allocation (in perf/compiler).  That seems fine.
      
      There is a big runtime improvement in T10359
      
      Metric Decrease:
          LargeRecord
          MultiLayerModulesTH_OneShot
          T13386
          T13719
      Metric Increase:
          T8095
      778c6adc
  31. Nov 09, 2022
    • Giles Anderson's avatar
      Use TcRnDiagnostic in GHC.Tc.TyCl.Instance (#20117) · 92ccb8de
      Giles Anderson authored and Marge Bot's avatar Marge Bot committed
      The following `TcRnDiagnostic` messages have been introduced:
      
      TcRnWarnUnsatisfiedMinimalDefinition
      TcRnMisplacedInstSig
      TcRnBadBootFamInstDeclErr
      TcRnIllegalFamilyInstance
      TcRnAssocInClassErr
      TcRnBadFamInstDecl
      TcRnNotOpenFamily
      92ccb8de
  32. Oct 26, 2022
  33. Oct 22, 2022
  34. Oct 13, 2022
  35. Sep 27, 2022
  36. Sep 20, 2022
    • Vladislav Zavialov's avatar
      Fix -Woperator-whitespace for consym (part of #19372) · 59fe128c
      Vladislav Zavialov authored and Marge Bot's avatar Marge Bot committed
      Due to an oversight, the initial specification and implementation of
      -Woperator-whitespace focused on varsym exclusively and completely
      ignored consym.
      
      This meant that expressions such as "x+ y" would produce a warning,
      while "x:+ y" would not.
      
      The specification was corrected in ghc-proposals pull request #404,
      and this patch updates the implementation accordingly.
      
      Regression test included.
      59fe128c
  37. Sep 19, 2022
    • Matthew Farkas-Dyck's avatar
      Scrub partiality about `NewOrData`. · c1f81b38
      Matthew Farkas-Dyck authored and Marge Bot's avatar Marge Bot committed
      Rather than a list of constructors and a `NewOrData` flag, we define `data DataDefnCons a = NewTypeCon a | DataTypeCons [a]`, which enforces a newtype to have exactly one constructor.
      
      Closes #22070.
      
      Bump haddock submodule.
      c1f81b38
  38. Sep 13, 2022
    • sheaf's avatar
      Diagnostic codes: acccept test changes · 362cca13
      sheaf authored and Marge Bot's avatar Marge Bot committed
      The testsuite output now contains diagnostic codes, so many tests need
      to be updated at once.
      We decided it was best to keep the diagnostic codes in the testsuite
      output, so that contributors don't inadvertently make changes to the
      diagnostic codes.
      362cca13
Loading