Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fix regression causing `namespace\foo();` to match as meta.namespace.php

  • Loading branch information...
commit d96d31af6a2b085fcbfc7bc8985165c168133622 1 parent 4be1fbe
Josh Varner authored December 08, 2010 Josh Varner committed February 06, 2012

Showing 1 changed file with 2 additions and 2 deletions. Show diff stats Hide diff stats

  1. 4  Syntaxes/PHP.plist
4  Syntaxes/PHP.plist
@@ -1249,7 +1249,7 @@
1249 1249
 				</dict>
1250 1250
 				<dict>
1251 1251
 					<key>begin</key>
1252  
-					<string>(?i)^\s*(namespace)\b</string>
  1252
+					<string>(?i)^\s*(namespace)\b\s+(?=([a-z0-9_\\]+\s*($|[;{]|(\/[\/*])))|$)</string>
1253 1253
 					<key>beginCaptures</key>
1254 1254
 					<dict>
1255 1255
 						<key>1</key>
@@ -1261,7 +1261,7 @@
1261 1261
 					<key>contentName</key>
1262 1262
 					<string>entity.name.type.namespace.php</string>
1263 1263
 					<key>end</key>
1264  
-					<string>$|(?=[;{])</string>
  1264
+					<string>(?i)(?=\s*$|[^a-z0-9_\\])</string>
1265 1265
 					<key>name</key>
1266 1266
 					<string>meta.namespace.php</string>
1267 1267
 					<key>patterns</key>

0 notes on commit d96d31a

Please sign in to comment.
Something went wrong with that request. Please try again.