[Bug 59921] phpsupport doesn't handle reference operator for functions
Amilcar do Carmo Lucas
amilcar at ida.ing.tu-bs.de
Thu Aug 21 16:13:35 UTC 2003
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=59921
amilcar at ida.ing.tu-bs.de changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
------- Additional Comments From amilcar at ida.ing.tu-bs.de 2003-08-21 16:10 -------
Subject: kdevelop/parts/phpsupport
CVS commit by aclu:
Fix the php parser to parse functions which are returning by reference. (BR 59921)
i.e:
class foo
{
var $data;
function &bar()
{
return $data;
}
}
Patch by: Klaus Dorninger ( klaus in xweb.cc)
CCMAIL: 59921-done at bugs.kde.org
M +2 -2 phpparser.cpp 1.15
--- kdevelop/parts/phpsupport/phpparser.cpp #1.14:1.15
@@ -146,7 +146,7 @@ void PHPParser::parseFile(const QString&
KRegExp classre("^[ \t]*class[ \t]+([A-Za-z_]+)[ \t]*(extends[ \t]*([A-Za-z_]+))?.*$");
- KRegExp methodre("^[ \t]*function[ \t]*([0-9A-Za-z_]*)[ \t]*\\(([0-9A-Za-z_\\$\\, \t=&\\'\\\"]*)\\).*$");
+ KRegExp methodre("^[ \t]*function[ \t&]*([0-9A-Za-z_]*)[ \t]*\\(([0-9A-Za-z_\\$\\, \t=&\\'\\\"]*)\\).*$");
KRegExp varre("^[ \t]*var[ \t]*([0-9A-Za-z_\\$]+)[ \t;=].*$");
- KRegExp createMemberRe("\\$this->([0-9A-Za-z_]+)[ \t]*=[ \t]*new[ \t]+([0-9A-Za-z_]+)");
+ KRegExp createMemberRe("\\$this->([0-9A-Za-z_]+)[ \t]*=[ \t&]*new[ \t]+([0-9A-Za-z_]+)");
ParsedClass *lastClass = 0;
More information about the KDevelop-devel
mailing list