Ok, I have been trying to find a regular expression in lex that will recognize a C-like string literal in an input string. eg. in printf("stackoverflow")
, "stackoverflow" should be recognized as a string literal.
I have been trying the following:
"[.]+"
["][.]+["]
\"[.]+\"
[\"][.]+[\"]
"""[.]+"""
None of these is working. The lexeme recognized each time is " alone. What should I do? Thanks in advance...