Re: Outlaw tabs

2009-01-25 Thread Twan van Laarhoven
Jon Fairbairn wrote: Warnings are the wrong answer to this problem. In fact, they're rarely the right answer to any problem. Tabs in sourcecode can have bad effects, and Haskell is a language that attempts to reject bad effects as far as possible. Nor can I see any argument in favour of

Re: Haskell' - class aliases

2008-04-25 Thread Twan van Laarhoven
Simon Peyton-Jones wrote: Is this the most up-to-date description of the proposal? http://repetae.net/recent/out/classalias.html Has anyone looked at my (confusingly named and horribly written) variant? http://haskell.org/haskellwiki/Superclass_defaults My idea is to split

Re: Suggestion regarding (.) and map

2008-04-24 Thread Twan van Laarhoven
Cale Gibbard wrote: Hello, In keeping with my small but seemingly extremely controversial suggestions for changes to the Prelude, here's a suggestion which I think is elegant and worth considering for the Haskell' Prelude: Rename fmap to map (like it was in Haskell 1.4), and define (.) as a

Consistency of reserved operators and bang patterns

2007-09-07 Thread Twan van Laarhoven
The bang pattern proposal [1] still allows (!) to be used as an operator. I think there should be no difference in this regard between ! and ~, since they are used in exactly the same location. In my opinion the best thing would be to allow (~) and (@) as operators. With the same restriction

Re: Wanted: warning option for usages of unary minus

2007-05-17 Thread Twan van Laarhoven
Simon Marlow wrote: ... Really? I'm beginning to have second thoughts about the proposed change to negation for Haskell'. The main reason, and this isn't pointed out as well as it should be on the wiki, is that x-1 will cease to be an infix application of (-), it will parse as x applied to

Deriving Functor

2007-03-08 Thread Twan van Laarhoven
(cofmap_a,x f) . fmap (cofmap_a,y f) Thereby removing all uses of CoFunctor. Maybe that would be a better definition? Finally, if Data.Foldable and Data.Traversable are added to the standard, they could be derived in a similair way. Twan van Laarhoven

Re: character literal question

2006-12-01 Thread Twan van Laarhoven
Iavor Diatchki wrote: Hello, Is there a reason why we have to escape the character ' (apostrophe) when used in a character literal? For example, we have to write '\'' instead of '''. (With syntax highlighting, the second is a lot better looking than the first.) It seems that in this case we

Specification of newtype deriving

2006-03-30 Thread Twan van Laarhoven
The Trac page for 'Generalised deriving for newtype' remarks that it is 'difficult to specify without saying the same representation'. I assume that no one has tried yet, so I'll take a shot at it. Say we have a declaration of the form: class C a where x :: T a -- any type that can