
31 May
2007
31 May
'07
6:18 a.m.
Jon,
This is a crazy idea I've been working on: overload the syntax "x y" so it can mean function application "f x = f(x)" or multiplication "x y = x*y".
On a related (?) note, but definitely not what you're after: there are constructor classes that allow you to lift function application into a functor and equip it with specific semantics: fmap :: (Functor f) => (a -> b) -> f a -> f b (<*>) :: (Applicative f) => f (a -> b) -> f a -> f b (=<<) :: (Monad m) => (a -> m b) -> m a -> m b Cheers, Stefan