I am trying to write a parser that glues two characters into a string:
(<:>) = liftM2 (\a b -> [a, b])
mychar :: Parser String
mychar = (char '\\') <:> (noneOf "u")
is it possible to make it more elegant? I am a newbie. Please help.
Another choice is:
mychar = sequence [char '\\', noneof "u"]