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

January 2015

  • 2 participants
  • 856 discussions
Re: [GHC] #7485: Tuple constraints not properly kinded
by GHC 06 Jan '15

06 Jan '15
#7485: Tuple constraints not properly kinded -------------------------------------+------------------------------------- Reporter: goldfire | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.7 Resolution: invalid | Keywords: Operating System: Unknown/Multiple | ConstraintKinds Type of failure: None/Unknown | Architecture: Blocked By: | Unknown/Multiple Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by ekmett): FWIW- After Simon posted the original suggestion for how to do this, Dan Doel and I implemented it without problem in Ermine in an afternoon. It is a rather nice fix for this problem. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/7485#comment:6> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #7485: Tuple constraints not properly kinded
by GHC 06 Jan '15

06 Jan '15
#7485: Tuple constraints not properly kinded -------------------------------------+------------------------------------- Reporter: goldfire | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.7 Resolution: invalid | Keywords: Operating System: Unknown/Multiple | ConstraintKinds Type of failure: None/Unknown | Architecture: Blocked By: | Unknown/Multiple Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by goldfire): Replying to [comment:3 crockeea]: > Is @simonpj 's comment > > `(,)` has to have a particular kind > still true with advent of `-XPolyKinds`? Yes. The problem is that `(,)` isn't really poly-kinded. It's not, for example, `k -> k -> k`. It's either `* -> * -> *` or `Constraint -> Constraint -> Constraint`, and there's no way of saying this in normal Haskell. So, we have the hack Simon describes above. One possible way forward is to follow the NoSubKinds route: introduce a new type `ValueKind` parameterized by elements of `data StarOrConstraint = Star | Ct`. Then `*` would be a synonym for `ValueKind Star` and `Constraint` would be `ValueKind Ct`. We would then have `(,) :: forall (x :: StarOrConstraint). ValueKind x -> ValueKind x -> ValueKind x`. This would be very hard to implement before merging my DependentHaskell branch though, because it requires kind synonyms and other funny business. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/7485#comment:5> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
[GHC] #9939: Warn for duplicate superclass constraints
by GHC 06 Jan '15

06 Jan '15
#9939: Warn for duplicate superclass constraints -------------------------------------+------------------------------------- Reporter: crockeea | Owner: Type: feature | Status: new request | Milestone: Priority: normal | Version: 7.8.3 Component: Compiler | Operating System: Unknown/Multiple Keywords: | Type of failure: None/Unknown Architecture: | Blocked By: Unknown/Multiple | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- With the following code, GHC warns that there are duplicate constraints: {{{#!hs {-# LANGUAGE FlexibleInstances, UndecidableInstances #-} module Foo where class Foo a where foo :: Int -> a instance (Integral a, Integral a) => Foo a where foo x = (fromIntegral x) `div` 2 }}} However, when writing the code, I might start with: {{{#!hs {-# LANGUAGE FlexibleInstances, UndecidableInstances #-} module Foo where class Foo a where foo :: Int -> a instance Foo a where foo x = (fromIntegral x) `div` 2 }}} without any constraints on the instance. GHC complains that it needs `Num a` and `Integral a`, but of course `Num` is implied by `Integral`. I'm ''not'' asking that GHC figure this out on its own and only request the strongest constraint necessary. Rather, I'm suggesting that ''if'' I followed GHC's suggestion and wrote {{{#!hs {-# LANGUAGE FlexibleInstances, UndecidableInstances #-} module Foo where class Foo a where foo :: Int -> a instance (Num a, Integral a) => Foo a where foo x = (fromIntegral x) `div` 2 }}} then GHC should warn {{{ Duplicate constraint(s): Num a In the context: (Num a, Integral a) (Num a) is implied by (Integral a) }}} or something similar. The motivation for this feature request is that in large instances/programs, it is difficult for a human to keep track of superclasses. In large instances, GHC tends to request "weak" constraints first (say `Num`), then ask for progressively stronger constraints (say `Integral`). Again, I'm not suggesting that behavior should change. However, it tends to lead to instances that look like `(Num a, Real a, RealFrac a, RealFloat a) => ...` if by chance I happened to use methods from each class. It seems fairly simple for GHC to look at each constraint for an instance (or function), trace back up the class hierarchy to get a set of all implied constraints, and then warn if one set is a subset of another. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9939> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 4
0 0
Re: [GHC] #4150: CPP+QuasiQuotes confuses compilation errors' line numbers
by GHC 06 Jan '15

06 Jan '15
#4150: CPP+QuasiQuotes confuses compilation errors' line numbers -------------------------------------+------------------------------------- Reporter: yairchu | Owner: Type: bug | Status: new Priority: low | Milestone: 7.12.1 Component: Compiler | Version: 6.12.3 (Parser) | Keywords: Resolution: | Architecture: Operating System: Unknown/Multiple | Unknown/Multiple Type of failure: Incorrect | Test Case: warning at compile-time | quasiquotation/T4150 Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by crobbins): I've been able to reproduce the issue; see the gist below. Hopefully this should be simple to incorporate into a test case. https://gist.github.com/carymrobbins/8345cdcf7830fd6b1a6e Thanks again for your help! I doubt I could be much help in the implementation department, but if there's anything else I can do let me know. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4150#comment:13> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #7485: Tuple constraints not properly kinded
by GHC 05 Jan '15

05 Jan '15
#7485: Tuple constraints not properly kinded -------------------------------------+------------------------------------- Reporter: goldfire | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.7 Resolution: invalid | Keywords: Operating System: Unknown/Multiple | ConstraintKinds Type of failure: None/Unknown | Architecture: Blocked By: | Unknown/Multiple Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Changes (by crockeea): * cc: ecrockett0@… (added) -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/7485#comment:4> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #7485: Tuple constraints not properly kinded
by GHC 05 Jan '15

05 Jan '15
#7485: Tuple constraints not properly kinded -------------------------------------+------------------------------------- Reporter: goldfire | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.7 Resolution: invalid | Keywords: Operating System: Unknown/Multiple | ConstraintKinds Type of failure: None/Unknown | Architecture: Blocked By: | Unknown/Multiple Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by crockeea): Is @simonpj 's comment > `(,)` has to have a particular kind still true with advent of `-XPolyKinds`? -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/7485#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #4150: CPP+QuasiQuotes confuses compilation errors' line numbers
by GHC 05 Jan '15

05 Jan '15
#4150: CPP+QuasiQuotes confuses compilation errors' line numbers -------------------------------------+------------------------------------- Reporter: yairchu | Owner: Type: bug | Status: new Priority: low | Milestone: 7.12.1 Component: Compiler | Version: 6.12.3 (Parser) | Keywords: Resolution: | Architecture: Operating System: Unknown/Multiple | Unknown/Multiple Type of failure: Incorrect | Test Case: warning at compile-time | quasiquotation/T4150 Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by simonpj): We can certainly fix bugs in 7.10, yes. So if you can make a patch to fix it, and it's not too invasive or destablising, we can apply it to the 7.10 release candidate. Simon -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4150#comment:12> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #4150: CPP+QuasiQuotes confuses compilation errors' line numbers
by GHC 04 Jan '15

04 Jan '15
#4150: CPP+QuasiQuotes confuses compilation errors' line numbers -------------------------------------+------------------------------------- Reporter: yairchu | Owner: Type: bug | Status: new Priority: low | Milestone: 7.12.1 Component: Compiler | Version: 6.12.3 (Parser) | Keywords: Resolution: | Architecture: Operating System: Unknown/Multiple | Unknown/Multiple Type of failure: Incorrect | Test Case: warning at compile-time | quasiquotation/T4150 Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by crobbins): Thanks ezyang! I'll work on getting a test case together. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4150#comment:11> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #4150: CPP+QuasiQuotes confuses compilation errors' line numbers
by GHC 04 Jan '15

04 Jan '15
#4150: CPP+QuasiQuotes confuses compilation errors' line numbers -------------------------------------+------------------------------------- Reporter: yairchu | Owner: Type: bug | Status: new Priority: low | Milestone: 7.12.1 Component: Compiler | Version: 6.12.3 (Parser) | Keywords: Resolution: | Architecture: Operating System: Unknown/Multiple | Unknown/Multiple Type of failure: Incorrect | Test Case: warning at compile-time | quasiquotation/T4150 Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by ezyang): So, to fix this, we need to augment the multi-line comment and quasi-quote lexing in `Lexer.x` to look for and handle the CPP produced line pragmas (as handled currently by the `<bol>` state). It should be possible, though a bit delicate since both of these lexers are hand-rolled. While I was reading how this code worked, I realized there is a workaround: if you force the line-state to resynchronize, e.g. by include'ing a blank file outside of the quasiquote/multiline comment, you'll get right light numbers for anything afterwards. If you want this in 7.10 (there's not much time left) you can help out by cooking up a self-contained, minimal example for quasiquoters which we can put in the test suite. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4150#comment:10> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
Re: [GHC] #4150: CPP+QuasiQuotes confuses compilation errors' line numbers
by GHC 04 Jan '15

04 Jan '15
#4150: CPP+QuasiQuotes confuses compilation errors' line numbers -------------------------------------+------------------------------------- Reporter: yairchu | Owner: Type: bug | Status: new Priority: low | Milestone: 7.12.1 Component: Compiler | Version: 6.12.3 (Parser) | Keywords: Resolution: | Architecture: Operating System: Unknown/Multiple | Unknown/Multiple Type of failure: Incorrect | Test Case: warning at compile-time | quasiquotation/T4150 Blocked By: | Blocking: Related Tickets: | Differential Revisions: -------------------------------------+------------------------------------- Comment (by crobbins): Is there any way we could move this back to 7.10.1? This makes integration with tools very error-prone. For instance, error highlighting in your editor will be in the wrong place. Any feature that requires an accurate line/column position will work inconsistently for end users as a result. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/4150#comment:9> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 82
  • 83
  • 84
  • 85
  • 86
  • Older →

HyperKitty Powered by HyperKitty version 1.3.9.