Kaydet (Commit) 9c94b5b3 authored tarafından Nick Treleaven's avatar Nick Treleaven

Parse PHP final functions (fixes #3111171).


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5417 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst 554f1b05
......@@ -9,6 +9,8 @@
Don't change default build command entry color when cancelling
label editing.
Make dialogs_show_input() return NULL when cancelled.
* tagmanager/php.c:
Parse PHP final functions (fixes #3111171).
2010-11-17 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
......
......@@ -79,9 +79,10 @@ static void installPHPRegex (const langType language)
"\\1", "m,macro,macros", NULL);
addTagRegex(language, "^[ \t]*const[ \t]*([" ALPHA "_][" ALNUM "_]*)[ \t]*[=;]",
"\\1", "m,macro,macros", NULL);
/* Note: Using [] to match words is wrong, but using () doesn't seem to match 'function' on its own */
addCallbackRegex(language,
"^[ \t]*[(public|protected|private|static)[ \t]*]*[ \t]*function[ \t]+&?[ \t]*([" ALPHA "_][" ALNUM "_]*)[[:space:]]*(\\(.*\\))",
NULL, function_cb);
"^[ \t]*[(public|protected|private|static|final)[ \t]*]*[ \t]*function[ \t]+&?[ \t]*([" ALPHA "_][" ALNUM "_]*)[[:space:]]*(\\(.*\\))",
NULL, function_cb);
addTagRegex(language, "^[ \t]*(\\$|::\\$|\\$this->)([" ALPHA "_][" ALNUM "_]*)[ \t]*=",
"\\2", "v,variable,variables", NULL);
addTagRegex(language, "^[ \t]*((var|public|protected|private|static)[ \t]+)+\\$([" ALPHA "_][" ALNUM "_]*)[ \t]*[=;]",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment