9
I am having a big problem to write a regexp that will trim all the whitespace in my input.
I have tried \s+ and [ \t\t\r]+ but that don't work.
I need this because I am writing a scanner using flex, and I am stuck at matching whitespace. The whitespace should just be matched and not removed.
Example input:
program
3.3 5 7
{ comment }
string
panic: cant happen