Re: [GHC] #7532: -ddump-splices output doesn't match generated code for data instances inside instances.

2013-01-02 Thread GHC
#7532: -ddump-splices output doesn't match generated code for data instances
inside instances.
---+
  Reporter:  Aninhumer |  Owner:  
  Type:  bug   | Status:  closed  
  Priority:  normal|  Milestone:  
 Component:  Template Haskell  |Version:  7.6.1   
Resolution:  fixed |   Keywords:  
Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
   Failure:  None/Unknown  | Difficulty:  Unknown 
  Testcase:  th/T7532  |  Blockedby:  
  Blocking:|Related:  
---+
Changes (by simonpj):

  * status:  new => closed
  * difficulty:  => Unknown
  * resolution:  => fixed
  * testcase:  => th/T7532


Comment:

 Good point, thank you.  A pretty printing bug, now fixed.

 I don't think this is worth merging to 7.6 becuase that code has changed a
 bit, so it'll need a bit of fiddling and it's not a big deal.

 Simon

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler

___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


Re: [GHC] #7532: -ddump-splices output doesn't match generated code for data instances inside instances.

2013-01-02 Thread GHC
#7532: -ddump-splices output doesn't match generated code for data instances
inside instances.
-+--
Reporter:  Aninhumer |  Owner:  
Type:  bug   | Status:  new 
Priority:  normal|  Component:  Template Haskell
 Version:  7.6.1 |   Keywords:  
  Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
 Failure:  None/Unknown  |  Blockedby:  
Blocking:|Related:  
-+--

Comment(by simonpj@…):

 commit 9b9f197b05c4bf9d16289d3aa6e71e9f081da7f6
 {{{
 Author: Simon Peyton Jones 
 Date:   Wed Jan 2 12:37:07 2013 +

 Improve HsSyn pretty-printing of instance declarations (fixes Trac
 #7532)

  compiler/hsSyn/HsDecls.lhs |   42
 +++---
  1 files changed, 27 insertions(+), 15 deletions(-)
 }}}

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler

___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs


[GHC] #7532: -ddump-splices output doesn't match generated code for data instances inside instances.

2012-12-26 Thread GHC
#7532: -ddump-splices output doesn't match generated code for data instances
inside instances.
-+--
Reporter:  Aninhumer |  Owner:  
Type:  bug   | Status:  new 
Priority:  normal|  Component:  Template Haskell
 Version:  7.6.1 |   Keywords:  
  Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
 Failure:  None/Unknown  |  Blockedby:  
Blocking:|Related:  
-+--
 Using the following code:
 {{{
 {-# LANGUAGE TemplateHaskell #-}
 {-# LANGUAGE TypeFamilies #-}

 module Test where

 import Language.Haskell.TH

 class C a where
 data D a

 bang :: DecsQ
 bang = return [
 InstanceD [] (AppT (ConT ''C) (ConT ''Int)) [
 DataInstD [] ''D [ConT ''Int] [
 NormalC (mkName "T") []] []]]
 }}}

 {{{
 {-# LANGUAGE TemplateHaskell #-}
 {-# LANGUAGE TypeFamilies #-}

 import Language.Haskell.TH
 import Test

 $(bang)
 }}}
 When compiling the second file in GHCi with -ddump-splices set, the output
 is:
 {{{
 th-test2.hs:1:1: Splicing declarations
 bang
   ==>
 th-test2.hs:9:3-6
 instance C Int where
   data instance D Int = T
 Ok, modules loaded: Test, Main.
 }}}
 This compiles successfully, but the dumped splice is clearly incorrect
 (which I confirmed by attempting to splice this code manually into the
 same place).

-- 
Ticket URL: 
GHC 
The Glasgow Haskell Compiler

___
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs