Correct, you're stuck always writing it with the parenthese because without them; you get an infix function which is binary, not unary.

I still don't see what your solution brings new to the table in relevance to the question. It's just trading a poorly named function for arguably an even worse.

On May 16, 2016 10:20 AM, "Imants Cekusins" <imantc@gmail.com> wrote:
> Alex

here  is what I tried:

(%%):: Applicative f => a -> f a
(%%) = pure


test::Int -> IO Int
test i0 = (%%) $ i0 + (2::Int)


seems to work..

I can't get %% to work without ()

_______________________________________________
Beginners mailing list
Beginners@haskell.org
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners