
29 Sep
2008
29 Sep
'08
10:55 p.m.
On Mon, Sep 29, 2008 at 9:40 AM, apfelmus
Alexander Dunlap wrote:
This seems like a good idea but it's kind of strange to have three different exposed versions of nub. Would it be possible to hide them, hide the StopList typeclass and use {-# RULES #-} pragmas to use the faster versions when possible?
I don't think that using RULES pragmas is a good solution to the problem.
Why not? I thought that was the major purpose of RULES - to implement transformations that don't affect semantics. It seems silly to clutter up classes with extra functions just for efficiency or to have to change programs every time the types change. The fact that RULES don't work in GHCi is admittedly a downside; is there any plan to change that? Alex