Haskell.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

ghc-tickets

Thread Start a new thread
Download
Threads by month
  • ----- 2025 -----
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2021 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2020 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2019 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2018 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2017 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2016 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2015 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2014 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2013 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
ghc-tickets@haskell.org

March 2018

  • 1 participants
  • 1031 discussions
[GHC] #14817: GHC 8.4.1 pretty-prints data family instances with redundant kind signatures using -ddump-splices
by GHC 02 Mar '18

02 Mar '18
#14817: GHC 8.4.1 pretty-prints data family instances with redundant kind signatures using -ddump-splices -------------------------------------+------------------------------------- Reporter: RyanGlScott | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.4.1-alpha3 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- Consider this program: {{{#!hs {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeFamilies #-} {-# OPTIONS_GHC -ddump-splices #-} module Bug where $([d| data family Foo :: * data instance Foo :: * |]) }}} On GHC 8.2.2, this gives the following `-ddump-splices` output: {{{ $ /opt/ghc/8.2.2/bin/ghci Bug.hs GHCi, version 8.2.2: http://www.haskell.org/ghc/ :? for help Loaded GHCi configuration from /home/rgscott/.ghci [1 of 1] Compiling Bug ( Bug.hs, interpreted ) Bug.hs:(6,3)-(7,31): Splicing declarations [d| data family Foo_a1sB :: * data instance :: * |] ======> data family Foo_a494 :: GHC.Types.Type data instance :: GHC.Types.Type }}} But on GHC 8.4.1, we have: {{{ $ /opt/ghc/8.4.1/bin/ghci Bug.hs GHCi, version 8.4.0.20180209: http://www.haskell.org/ghc/ :? for help Loaded GHCi configuration from /home/rgscott/.ghci [1 of 1] Compiling Bug ( Bug.hs, interpreted ) Bug.hs:(6,3)-(7,31): Splicing declarations [d| data family Foo_a1xd :: * data instance Foo_a1xd :: * :: * |] ======> data family Foo_a487 :: GHC.Types.Type data instance Foo_a487 :: GHC.Types.Type :: GHC.Types.Type }}} Notice how there is a redundant kind signature in `data instance Foo_a1xd :: * :: *`. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14817> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 3
0 0
[GHC] #14819: GHC 8.2 does not accept British {-# LANGUAGE GeneralisedNewtypeDeriving #-} spelling
by GHC 02 Mar '18

02 Mar '18
#14819: GHC 8.2 does not accept British {-# LANGUAGE GeneralisedNewtypeDeriving #-} spelling -------------------------------------+------------------------------------- Reporter: clinton | Owner: (none) Type: bug | Status: new Priority: lowest | Milestone: Component: Compiler | Version: 8.2.2 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: GHC rejects Unknown/Multiple | valid program Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- The GHC docs for GeneralisedNewtypeDeriving at (https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/glasgow_ext… #generalised-derived-instances-for-newtypes) suggest British spelling should be accepted, and indeed it's the preferred spelling in the docs. However GHC 8.2 throws an error. I haven't tested this against HEAD so if it's fixed there please feel free to close. I know this is a bit picky but it's caught me out a few times and I couldn't see it previously reported (I may have missed it though). -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14819> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 5
0 0
Re: [GHC] #4012: Compilation results are not deterministic
by GHC 02 Mar '18

02 Mar '18
#4012: Compilation results are not deterministic -------------------------------------+------------------------------------- Reporter: kili | Owner: niteria Type: bug | Status: new Priority: high | Milestone: 8.6.1 Component: Compiler | Version: 6.12.2 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: Other | Test Case: Blocked By: 11362 | Blocking: 12262 Related Tickets: #10424 | Differential Rev(s): Phab:D910, | Phab:D1073, Phab:D1133, Phab:D1192, | Phab:D1268, Phab:D1360, Phab:D1373, | Phab:D1396, Phab:D1457, Phab:D1468, Wiki Page: | Phab:D1487, Phab:D1504, Phab:D1508, DeterministicBuilds | Phab:D4388 -------------------------------------+------------------------------------- Comment (by Ben Gamari <ben@…>): In [changeset:"d8e47a2ea89dbce647b06132ec10c39a2de67437/ghc" d8e47a2e/ghc]: {{{ #!CommitTicketReference repository="ghc" revision="d8e47a2ea89dbce647b06132ec10c39a2de67437" Make cost centre symbol names deterministic. Previously, non-CAF cost centre symbol names contained a unique, leading to non-deterministic object files which, among other issues, can lead to an inconsistency causing linking failure when using cached builds sourced from multiple machines, such as with nix. Now, each cost centre symbol is annotated with the type of cost centre it is (CAF, expression annotation, declaration annotation, or HPC) and, when a single module has multiple cost centres with the same name and type, a 0-based index. Reviewers: bgamari, simonmar Reviewed By: bgamari Subscribers: niteria, simonmar, RyanGlScott, osa1, rwbarton, thomie, carter GHC Trac Issues: #4012, #12935 Differential Revision: https://phabricator.haskell.org/D4388 }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4012#comment:245> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #2893: Implement "Quantified constraints" proposal
by GHC 02 Mar '18

02 Mar '18
#2893: Implement "Quantified constraints" proposal -------------------------------------+------------------------------------- Reporter: porges | Owner: (none) Type: feature request | Status: new Priority: normal | Milestone: ⊥ Component: Compiler | Version: 6.10.1 Resolution: | Keywords: | QuantifiedConstraints Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: #5927 | Differential Rev(s): Phab:D4353 Wiki Page: | -------------------------------------+------------------------------------- Comment (by simonpj): Replying to [comment:36 Iceland_jack]: > `f` should have an `Ord a` constraint right? You mean in the commit message? Yes, you're right. (Before putting this on master I'll squash all the commits and write a new message.) -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/2893#comment:37> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #2893: Implement "Quantified constraints" proposal
by GHC 02 Mar '18

02 Mar '18
#2893: Implement "Quantified constraints" proposal -------------------------------------+------------------------------------- Reporter: porges | Owner: (none) Type: feature request | Status: new Priority: normal | Milestone: ⊥ Component: Compiler | Version: 6.10.1 Resolution: | Keywords: | QuantifiedConstraints Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: #5927 | Differential Rev(s): Phab:D4353 Wiki Page: | -------------------------------------+------------------------------------- Comment (by Iceland_jack): `f` should have an `Ord a` constraint right? {{{#!hs f :: (Ord a, forall x. Ord x => Ord (m x)) => m a -> m a -> Bool }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/2893#comment:36> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #2893: Implement "Quantified constraints" proposal
by GHC 02 Mar '18

02 Mar '18
#2893: Implement "Quantified constraints" proposal -------------------------------------+------------------------------------- Reporter: porges | Owner: (none) Type: feature request | Status: new Priority: normal | Milestone: ⊥ Component: Compiler | Version: 6.10.1 Resolution: | Keywords: | QuantifiedConstraints Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: #5927 | Differential Rev(s): Phab:D4353 Wiki Page: | -------------------------------------+------------------------------------- Comment (by AntC): > ... superclass stufff ... Give it a whirl! Terrific. I'd appreciate if someone could test my hypothesis of a use case [1]. Note this using QuantifiedConstraints purely as implications with nothing `forall`'d.: > Consider modelling the logic for somewhat-injective type functions. > Take type-level Boolean `And` [5]. > > `And` is not fully injective but: > > * If the result is True, the two arguments must be True. > > * If the result is False and one argument is True, the other must be False. {{{ class ( (b3 ~ True) => (b1 ~ True, b2 ~ True), (b3 ~ False, b1 ~ True) => b2 ~ False, (b3 ~ False, b2 ~ True) => b1 ~ False ) => And (b1 :: Bool) (b2 :: Bool) (b3 :: Bool) | b1 b2 -> b3 where {} instance And True b2 b2 instance And False b2 False x3 = undefined :: (And b1 b2 True) => (b1, b2) -- should infer x3's type as :: (True, True) }}} [https://mail.haskell.org/pipermail/glasgow-haskell- users/2018-February/026694.html [1]] [https://mail.haskell.org/pipermail/ghc-devs/2017-November/015073.html [5]] [https://mail.haskell.org/pipermail/glasgow-haskell- users/2017-November/026650.html continued] -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/2893#comment:35> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #2893: Implement "Quantified constraints" proposal
by GHC 01 Mar '18

01 Mar '18
#2893: Implement "Quantified constraints" proposal -------------------------------------+------------------------------------- Reporter: porges | Owner: (none) Type: feature request | Status: new Priority: normal | Milestone: ⊥ Component: Compiler | Version: 6.10.1 Resolution: | Keywords: | QuantifiedConstraints Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: #5927 | Differential Rev(s): Phab:D4353 Wiki Page: | -------------------------------------+------------------------------------- Comment (by simonpj): I've added the superclass stuff {{{ commit 910dfcfeadc4f132e887bc4adf5ac2e17a29d99b Author: Simon Peyton Jones <simonpj(a)microsoft.com> Date: Thu Mar 1 23:32:29 2018 +0000 Add superclasses to quantified constraints This patch adds suppport for superclasses to quantified constraints. For example (contrived): f :: (forall a. Ord a => Ord (m a)) => m a -> m a -> Bool f x y = x==y Here we need (Eq (m a)); but the quantifed constraint deals only with Ord. But we can make it work by using its superclass. This behaviour finally delivers on the promise of comment:30 of Trac #9123: we can write an implication constraint that solves the problem of higher-kinded roles. Test quantified-constraints/T8123 demonstrates this in action. compiler/basicTypes/Id.hs | 2 +- compiler/typecheck/Inst.hs | 4 +- compiler/typecheck/TcCanonical.hs | 180 ++++++++++++++--------- compiler/typecheck/TcErrors.hs | 4 +- compiler/typecheck/TcEvTerm.hs | 5 +- compiler/typecheck/TcEvidence.hs | 74 ++++++---- compiler/typecheck/TcHsSyn.hs | 23 ++- compiler/typecheck/TcInstDcls.hs | 2 +- compiler/typecheck/TcInteract.hs | 61 ++++---- compiler/typecheck/TcMType.hs | 6 +- compiler/typecheck/TcPatSyn.hs | 7 +- compiler/typecheck/TcPluginM.hs | 2 +- compiler/typecheck/TcRnTypes.hs | 62 ++++++-- compiler/typecheck/TcSMonad.hs | 119 +++++++-------- compiler/typecheck/TcSimplify.hs | 2 +- compiler/typecheck/TcType.hs | 2 +- compiler/types/Class.hs | 54 ++++--- compiler/types/Kind.hs | 2 + testsuite/tests/quantified-constraints/T2893b.hs | 24 --- testsuite/tests/quantified-constraints/T2893c.hs | 15 ++ testsuite/tests/quantified-constraints/T9123.hs | 24 +++ testsuite/tests/quantified-constraints/T9123a.hs | 26 ++++ testsuite/tests/quantified-constraints/all.T | 5 + 23 files changed, 426 insertions(+), 279 deletions(-) }}} So now all the features I was planning are implemented. Give it a whirl! -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/2893#comment:34> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #3676: realToFrac doesn't sanely convert between floating types
by GHC 01 Mar '18

01 Mar '18
#3676: realToFrac doesn't sanely convert between floating types -------------------------------------+------------------------------------- Reporter: draconx | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: ⊥ Component: Core Libraries | Version: 6.12.1 Resolution: | Keywords: report-impact Operating System: Unknown/Multiple | Architecture: x86_64 | (amd64) Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by lelf): * cc: lelf (added) -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/3676#comment:27> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #1831: reify never provides the declaration of variables
by GHC 01 Mar '18

01 Mar '18
#1831: reify never provides the declaration of variables -------------------------------------+------------------------------------- Reporter: guest | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: ⊥ Component: Template Haskell | Version: 6.8.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by parsonsmatt): I'd like to register interest in having this available :) My specific use case is walking the AST from a given point to capture uses of `throw`, `throwM`, `throwIO`, etc. and try to get a list of possible exception types that might arise from a given function. eg: {{{ openFile' :: FilePath -> IO (Either IOException String) openFile' f = [catch|openFile f|] }}} It seems like this would be useful for other sorts of static analysis, as well. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/1831#comment:16> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
[GHC] #14856: GHC API: Linker failure on loading target multiple times
by GHC 01 Mar '18

01 Mar '18
#14856: GHC API: Linker failure on loading target multiple times ----------------------------------------+--------------------------- Reporter: fizzixnerd | Owner: (none) Type: bug | Status: new Priority: normal | Milestone: Component: GHC API | Version: 8.2.2 Keywords: GHC API Linker | Operating System: Linux Architecture: Unknown/Multiple | Type of failure: Other Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: ----------------------------------------+--------------------------- Minimum Working Example: https://github.com/Fizzixnerd/ghc-bug `stack exec -- ghc --version` >The Glorious Glasgow Haskell Compilation System, version 8.2.2 `uname --all` >Linux <REDACTED> 4.14.0-3-amd64 #1 SMP Debian 4.14.13-1 (2018-01-14) x86_64 GNU/Linux Description: Loading a dynamic module more than once causes a linker failure with the following message: ''' /usr/bin/ld.gold: error: cannot find -lghc_2 collect2: error: ld returned 1 exit status `gcc' failed in phase `Linker'. (Exit code: 1) *** Exception: ExitFailure 1 ''' `-lghc_2' sometimes is `-lghc_5' or other numbers. Steps to Reproduce: 1) Clone above repo. 2) `stack build` 3) `stack exec mwe-exe` The repo code will use the GHC API to load a string from the file contained in scripts/ named `val'. There are three functions defined in src/Lib.hs. `anotherFunc' should behave normally. `someFunc' should display the bad behavior. Notes: - When using `intero`: intero must be restarted if this bug is encountered at the prompt, or else you will keep getting it over and over again. - I could not figure out how to load it up without using the `-dynamic' flag, but that should probably be checked out too. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14856> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 2
0 0
  • ← Newer
  • 1
  • ...
  • 100
  • 101
  • 102
  • 103
  • 104
  • Older →

HyperKitty Powered by HyperKitty version 1.3.9.