Remove some apparerntly dead TH functions

This is a library propsal. There are a handful of functions in the template-haskell package, module Language.Haskell.TH.Lib, that are defined in that module, but are not used, and are not exported by the main Template Haskell interface Language.Haskell.TH. I propose to nuke them. I assume no one is using them (since they are not exported by the main interface), and I'm not keen on the API of rename. Moreover, rename becomes signficantly more compilcated with the advent of view patterns. The functions are: combine :: [([(Name, Name)], Pat)] -> ([(Name, Name)], [Pat]) -- Seems to be a helper for rename rename :: Pat -> Q ([(Name, Name)], Pat) genpat :: Pat -> Q ((Name -> ExpQ), Pat) alpha :: [(Name, Name)] -> Name -> ExpQ simpleMatch :: Pat -> Exp -> Match -- This is the most defensible; it's a "smart constructor" Deadline 2 weeks. http://hackage.haskell.org/trac/ghc/ticket/4423 Simon

Hi, +1. Cheers, Milan
This is a library propsal. There are a handful of functions in the template-haskell package, module Language.Haskell.TH.Lib, that are defined in that module, but are not used, and are not exported by the main Template Haskell interface Language.Haskell.TH. I propose to nuke them. I assume no one is using them (since they are not exported by the main interface), and I'm not keen on the API of rename. Moreover, rename becomes signficantly more compilcated with the advent of view patterns. The functions are: combine :: [([(Name, Name)], Pat)] -> ([(Name, Name)], [Pat]) -- Seems to be a helper for rename rename :: Pat -> Q ([(Name, Name)], Pat) genpat :: Pat -> Q ((Name -> ExpQ), Pat) alpha :: [(Name, Name)] -> Name -> ExpQ
simpleMatch :: Pat -> Exp -> Match -- This is the most defensible; it's a "smart constructor" Deadline 2 weeks. http://hackage.haskell.org/trac/ghc/ticket/4423 Simon
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries

+1
On Thu, Oct 21, 2010 at 4:30 AM, Milan Straka
Hi,
+1.
Cheers, Milan
This is a library propsal. There are a handful of functions in the template-haskell package, module Language.Haskell.TH.Lib, that are defined in that module, but are not used, and are not exported by the main Template Haskell interface Language.Haskell.TH. I propose to nuke them. I assume no one is using them (since they are not exported by the main interface), and I'm not keen on the API of rename. Moreover, rename becomes signficantly more compilcated with the advent of view patterns. The functions are: combine :: [([(Name, Name)], Pat)] -> ([(Name, Name)], [Pat]) -- Seems to be a helper for rename rename :: Pat -> Q ([(Name, Name)], Pat) genpat :: Pat -> Q ((Name -> ExpQ), Pat) alpha :: [(Name, Name)] -> Name -> ExpQ
simpleMatch :: Pat -> Exp -> Match -- This is the most defensible; it's a "smart constructor" Deadline 2 weeks. http://hackage.haskell.org/trac/ghc/ticket/4423 Simon
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries

+ 1 On Thursday 21 October 2010 10:14:44, Simon Peyton-Jones wrote:
This is a library propsal. There are a handful of functions in the template-haskell package, module Language.Haskell.TH.Lib, that are defined in that module, but are not used, and are not exported by the main Template Haskell interface Language.Haskell.TH. I propose to nuke them. I assume no one is using them (since they are not exported by the main interface), and I'm not keen on the API of rename. Moreover, rename becomes signficantly more compilcated with the advent of view patterns. The functions are: combine :: [([(Name, Name)], Pat)] -> ([(Name, Name)], [Pat]) -- Seems to be a helper for rename rename :: Pat -> Q ([(Name, Name)], Pat) genpat :: Pat -> Q ((Name -> ExpQ), Pat) alpha :: [(Name, Name)] -> Name -> ExpQ
simpleMatch :: Pat -> Exp -> Match -- This is the most defensible; it's a "smart constructor" Deadline 2 weeks. http://hackage.haskell.org/trac/ghc/ticket/4423 Simon

Do we know if any publicly released packages on Hackage would break from
this removal?
Not that that should be a blocker for a sensible change.
Thanks,
Antoine
On Oct 21, 2010 3:15 AM, "Simon Peyton-Jones"
This is a library propsal. There are a handful of functions in the template-haskell package, module Language.Haskell.TH.Lib, that are defined in that module, but are not used, and are not exported by the main Template Haskell interface Language.Haskell.TH. I propose to nuke them. I assume no one is using them (since they are not exported by the main interface), and I'm not keen on the API of rename. Moreover, rename becomes signficantly more compilcated with the advent of view patterns. The functions are: combine :: [([(Name, Name)], Pat)] -> ([(Name, Name)], [Pat]) -- Seems to be a helper for rename rename :: Pat -> Q ([(Name, Name)], Pat) genpat :: Pat -> Q ((Name -> ExpQ), Pat) alpha :: [(Name, Name)] -> Name -> ExpQ
simpleMatch :: Pat -> Exp -> Match -- This is the most defensible; it's a "smart constructor" Deadline 2 weeks. http://hackage.haskell.org/trac/ghc/ticket/4423 Simon

On Thu, Oct 21, 2010 at 07:49:08PM -0500, Antoine Latter wrote:
Do we know if any publicly released packages on Hackage would break from this removal?
The functions are: combine :: [([(Name, Name)], Pat)] -> ([(Name, Name)], [Pat]) -- Seems to be a helper for rename rename :: Pat -> Q ([(Name, Name)], Pat) genpat :: Pat -> Q ((Name -> ExpQ), Pat) alpha :: [(Name, Name)] -> Name -> ExpQ
simpleMatch :: Pat -> Exp -> Match
grepping hackage for genpat and simpleMatch finds no uses. Thanks Ian
participants (7)
-
Antoine Latter
-
Daniel Fischer
-
Edward Kmett
-
Ian Lynagh
-
Milan Straka
-
Sebastian Fischer
-
Simon Peyton-Jones