my regular expression :(?<=defining\s)[^;]*
should try to find var
in the following cases:
defining var;
some text defining var;
I tested the regular expression using some online tools. Unfortunately it does not work with Qt for some reason. Is there something wrong with the regular expression or should I look for the error somewhere else in the code? It is strange because regular expressions without lookbehind work.
Extra: a bit off topic but because I'm already writing the question: How do I have to change my regular expression so that it can find var in the following case with more then one whitespace:
some text defining var;
Right now it finds all but one whitespace and var.