Closed buptmiao closed 7 years ago
Thanks. I saw this work around, but it is too boring if there are too many reserved words.
Quoting an answer from stackoverflow
You could set case-insensitivity in the
.l
file:
%option caseless
You could call
flex -i
.Or you could state individual rules to be case-insensitive:
(?i:word)
Which of these options would be helpful in your use case?
I use the option below in flex.
%option case-insensitive
@buptmiao Please try checking out cznic/lex
branch case-insensitive
, then rebuild cznic/golex
and test with some .l
source. I did not actually tested if it works whatsoever, so please provide feedback. Thank you.
You are so great! It works now.
Thanks for testing it!
I think this feature is very usefull.