[solved]QRegExp doesn't support lookbehind assertions?
-
hello guys, Now I try to use QRegexp with the lookbehind synax "(?<=)", but i find it doesn't work, my code is as below.
@
QString test = "HELLO CHEN";
QRegExp reg("(?<=HELLO\s)[A-Za-z]*");
qDebug()<<reg.isValid(); //!< just output false;
@and, I fount a bug report in https://bugreports.qt-project.org/browse/QTBUG-2371.However,this bug has been closed, this page show that this bug will be fixed in version 5.0.0 .Now i run those code on 5.1.0, this bug is still there. Is it my own problem?
-
Hi,
The bug reports says that it's implemented in QRegularExpression, did you try that class ?
-
thanks, it work:)
[quote author="SGaist" date="1379281259"]Hi,The bug reports says that it's implemented in QRegularExpression, did you try that class ?[/quote]