Lines 11-16
Link Here
|
11 |
* variables. |
11 |
* variables. |
12 |
* |
12 |
* |
13 |
* Parsing PHP defines by Pavel Hlousek <pavel.hlousek@seznam.cz>, Apr 2003. |
13 |
* Parsing PHP defines by Pavel Hlousek <pavel.hlousek@seznam.cz>, Apr 2003. |
|
|
14 |
* Multiline comment fixes by David Mudrak <david.mudrak@gmail.com>, Jul 2009 |
15 |
* based on a patches by Sander Marechal <s.marechal@jejik.com>, Nov 2008. |
14 |
*/ |
16 |
*/ |
15 |
|
17 |
|
16 |
/* |
18 |
/* |
Lines 64-79
Link Here
|
64 |
|
66 |
|
65 |
static void installPHPRegex (const langType language) |
67 |
static void installPHPRegex (const langType language) |
66 |
{ |
68 |
{ |
67 |
addTagRegex(language, "(^|[ \t])class[ \t]+([" ALPHA "_][" ALNUM "_]*)", |
69 |
addTagRegex(language, "(^[ \t]*)(abstract[ \t]+)?class[ \t]+([" ALPHA "_][" ALNUM "_]*)", |
68 |
"\\2", "c,class,classes", NULL); |
70 |
"\\3", "c,class,classes", NULL); |
69 |
addTagRegex(language, "(^|[ \t])interface[ \t]+([" ALPHA "_][" ALNUM "_]*)", |
71 |
addTagRegex(language, "(^[ \t]*)interface[ \t]+([" ALPHA "_][" ALNUM "_]*)", |
70 |
"\\2", "i,interface,interfaces", NULL); |
72 |
"\\2", "i,interface,interfaces", NULL); |
71 |
addTagRegex(language, "(^|[ \t])define[ \t]*\\([ \t]*['\"]?([" ALPHA "_][" ALNUM "_]*)", |
73 |
addTagRegex(language, "(^[ \t]*)define[ \t]*\\([ \t]*['\"]?([" ALPHA "_][" ALNUM "_]*)", |
72 |
"\\2", "d,define,constant definitions", NULL); |
74 |
"\\2", "d,define,constant definitions", NULL); |
73 |
addTagRegex(language, "(^|[ \t])function[ \t]+&?[ \t]*([" ALPHA "_][" ALNUM "_]*)", |
75 |
addTagRegex(language, "(^[ \t]*)(public[ \t]+|protected[ \t]+|private[ \t]+)?(static[ \t]+)?function[ \t]+&?[ \t]*([" ALPHA "_][" ALNUM "_]*)", |
74 |
"\\2", "f,function,functions", NULL); |
76 |
"\\4", "f,function,functions", NULL); |
75 |
addTagRegex(language, "(^|[ \t])\\$([" ALPHA "_][" ALNUM "_]*)[ \t]*=", |
77 |
addTagRegex(language, "(^[ \t]*)(var[ \t]+|public[ \t]+|protected[ \t]+|private[ \t]+)?(static[ \t]+)?\\$([" ALPHA "_][" ALNUM "_]*)[ \t]*=", |
76 |
"\\2", "v,variable,variables", NULL); |
78 |
"\\4", "v,variable,variables", NULL); |
77 |
|
79 |
|
78 |
/* function regex is covered by PHP regex */ |
80 |
/* function regex is covered by PHP regex */ |
79 |
addTagRegex (language, "(^|[ \t])([A-Za-z0-9_]+)[ \t]*[=:][ \t]*function[ \t]*\\(", |
81 |
addTagRegex (language, "(^|[ \t])([A-Za-z0-9_]+)[ \t]*[=:][ \t]*function[ \t]*\\(", |