Am Dienstag, 27. September 2005 11:34 schrieb [EMAIL PROTECTED]: > Hi > i can not load program test1 into hugs, but test2 works. > Am i missing some special syntax? > > greetings, > Philip > > -------------- test1 ------------------ > > foo :: Maybe Int -> Int > foo Nothing =-1 > foo (Just a)= a > > -------------- test2 ------------------ > > foo :: Maybe Int -> Int > foo Nothing = -1 > -- ^ > -- +-- note an extra space > foo (Just a)= a
Hello, obviously, Hugs thinks that =- is a special operator. In Haskell you have the ability to define your own operators, so it would be possible to define an operator =-. I would suggest that you always put spaces around the = in declarations. Best wishes, Wolfgang _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe