1. 22 Apr, 2015 2 commits
  2. 21 Apr, 2015 1 commit
  3. 18 Apr, 2015 1 commit
  4. 17 Apr, 2015 2 commits
  5. 16 Apr, 2015 5 commits
  6. 15 Apr, 2015 2 commits
    • Joachim Breitner's avatar
      Improve Call Arity performance · a9ca67f6
      Joachim Breitner authored
      This improves how the Call Arity deals with "boring" variables. Boring
      variables are those where it does not bother to include in the analysis
      result, so whenever something is looked up in the analysis result, we
      have to make a conservative assumption about them.
      
      Previously, we extended the result with such conservative information
      about them, to keep the code uniform, but that could blow up the amount
      of data passed around, even if only temporarily, and slowed things down.
      
      We now pass around an explicit list (well, set) of variable that are
      boring and take that into account whenever we use the result. Not as
      pretty, but noticably faster.
      a9ca67f6
    • Simon Peyton Jones's avatar
      Fix fundep coverage-condition check for poly-kinds · 49d9b009
      Simon Peyton Jones authored
      See Note [Closing over kinds in coverage] in FunDeps.
      I'd already fixed this bug once, for Trac #8391, but I put the
      call to closeOverKinds in the wrong place, so Trac #10109
      failed.  (It checks the /liberal/ coverage condition, which
      
      The fix was easy: move the call to the right place!
      49d9b009
  7. 14 Apr, 2015 9 commits
    • Simon Peyton Jones's avatar
      Do not allow Typeable on constraints (Trac #9858) · 7b042d5a
      Simon Peyton Jones authored
      The astonishingly-ingenious trio of
      Shachaf Ben-Kiki, Ørjan Johansen and Nathan van Doorn
      managed to persuade GHC 7.10.1 to cough up unsafeCoerce.
      
      That is very bad. This patch fixes it by no allowing Typable
      on Constraint-kinded things.  And that seems right, since
      it is, in effect, a form of impredicative polymorphism,
      which Typeable definitely doesn't support.
      
      We may want to creep back in the direction of allowing
      Typeable on constraints one day, but this is a good
      fix for now, and closes a terrible hole.
      7b042d5a
    • Bertram Felgenhauer's avatar
      Implement -f[no-]print-unicode-syntax flag for unicode syntax output (#8959) · 6dd2765a
      Bertram Felgenhauer authored
      
      
      There is currently no way to separate whether UnicodeSyntax is accepted
      for input from the corresponding output syntax using unicode symbols.
      This patch implements a separate flag for affecting ghc(i)'s output.
      Signed-off-by: Bertram Felgenhauer's avatarBertram Felgenhauer <int-e@gmx.de>
      
      Reviewed By: nomeata, austin
      
      Differential Revision: https://phabricator.haskell.org/D807
      
      GHC Trac Issues: #8959
      6dd2765a
    • Alan Zimmerman's avatar
      ApiAnnotations : lexer discards comment close in nested comment · 5fded20c
      Alan Zimmerman authored
      When parsing a nested comment, such as
      
      {-
        {-  nested comment  -}
        {-# nested pragma  #-}
      -}
      
      The lexer returns the comment annotation as
      
      {-
        {-  nested comment
        {-# nested pragma  #
      -}
      
      Restore the missing comment end markers in the annotation.
      
      Reviewed By: austin
      
      Differential Revision: https://phabricator.haskell.org/D829
      
      GHC Trac Issues: #10277
      5fded20c
    • Alan Zimmerman's avatar
      API Annotations : ExprWithTySig processing discards annotated spans · 8dc29448
      Alan Zimmerman authored
      In RdrHsSyn.checkAPat the processing for ExprWithTySig is defined as
      
         ExprWithTySig e t _ -> do e <- checkLPat msg e
                                   -- Pattern signatures are parsed as sigtypes,
                                   -- but they aren't explicit forall points.  Hence
                                   -- we have to remove the implicit forall here.
                                   let t' = case t of
                                              L _ (HsForAllTy Implicit _ _
                                                   (L _ []) ty) -> ty
                                              other -> other
                                   return (SigPatIn e (mkHsWithBndrs t'))
      
      The t' variable ends up losing its original SrcSpan in the first case
      branch. This results in annotations becoming detached from the AST.
      
      Reviewed By: austin
      
      Differential Revision: https://phabricator.haskell.org/D823
      
      GHC Trac Issues: #10255
      8dc29448
    • Konstantine Rybnikov's avatar
      Add "error:" prefix to error-messages · 7febc2bb
      Konstantine Rybnikov authored
      Add "error:" prefix to error-messages, also lowercase "Warning:"
      message to match GCC behavior closer.
      
      Reviewed By: thomie, austin
      
      Differential Revision: https://phabricator.haskell.org/D811
      
      GHC Trac Issues: #10021
      7febc2bb
    • Simon Peyton Jones's avatar
      Zap usage info in CSE (Trac #10218) · d261d4cb
      Simon Peyton Jones authored
      Trac #10218 reports a subtle bug that turned out to be:
      
      - CSE invalidated the usage information computed
        by earlier demand analysis, by increasing sharing
      
      - that made a single-entry thunk into a multi-entry thunk
      
      - and with -feager-blackholing, that led to <<loop>>
      
      The patch fixes it by making the CSE pass zap usage information for
      let-bound identifiers.   It can be restored by -flate-dmd-anal.
      
      (But making -flate-dmd-anal the default needs some careful work;
      see Trac #7782.)
      d261d4cb
    • Alan Zimmerman's avatar
      parser : the API annotation on opt_sig is being discarded · 919b5117
      Alan Zimmerman authored
      The opt_sig production is defined as
      
        opt_sig :: { ([AddAnn],Maybe (LHsType RdrName)) }
                : {- empty -}                   { ([],Nothing) }
                | '::' sigtype                  { ([mj AnnDcolon $1],Just $2) }
      
      It is used in the alt and decl_no_th productions, but neither of them
      add the returned annotations.
      
      This commit captures the annotations in the calling productions.
      
      Reviewed By: austin
      
      Differential Revision: https://phabricator.haskell.org/D822
      
      GHC Trac Issues: #10254
      919b5117
    • Alan Zimmerman's avatar
      parser: API Annotations : guardquals1 does not annotate commas properly · 9eab6fee
      Alan Zimmerman authored
      The `guardquals1` production includes
      
         : guardquals1 ',' qual  {% addAnnotation (gl $ last $ unLoc $1) AnnComma
                                                   (gl $2) >>
                                     return (sLL $1 $> ($3 : unLoc $1)) }
      
      The AnnComma should be attached to `(gl $ head $ unLoc $1)`, rather than
      `last`.
      
      Reviewed By: austin
      
      Differential Revision: https://phabricator.haskell.org/D818
      
      GHC Trac Issues: #10256
      9eab6fee
    • Alan Zimmerman's avatar
      parser: opt_kind_sig has incorrect SrcSpan · 8aefc9b7
      Alan Zimmerman authored
      The production for opt_kind_sig is
      
        opt_kind_sig :: { Located (Maybe (LHsKind RdrName)) }
                :                             { noLoc Nothing }
                | '::' kind                   {% ajl (sLL $1 $> (Just $2)) AnnDcolon (gl $1) }
      
      The outer Location is used only to get the full span for the enclosing
      declration, and is then stripped. The inner LHsKind then has a SrcSpan that does
      not include the '::'
      
      Extend the SrcSpan on $2 to include $1
      
      Reviewed By: austin
      
      Differential Revision: https://phabricator.haskell.org/D813
      
      GHC Trac Issues: #10209
      8aefc9b7
  8. 10 Apr, 2015 1 commit
  9. 08 Apr, 2015 1 commit
  10. 07 Apr, 2015 16 commits