summaryrefslogtreecommitdiff
path: root/test/scanners/php/namespaces.in.php
diff options
context:
space:
mode:
Diffstat (limited to 'test/scanners/php/namespaces.in.php')
-rw-r--r--test/scanners/php/namespaces.in.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/scanners/php/namespaces.in.php b/test/scanners/php/namespaces.in.php
new file mode 100644
index 0000000..ad6a1a1
--- /dev/null
+++ b/test/scanners/php/namespaces.in.php
@@ -0,0 +1,9 @@
+<?php
+namespace foo;
+use blah\blah as foo;
+
+$a = new my\name(); // instantiates "foo\my\name" class
+foo\bar::name(); // calls static method "name" in class "blah\blah\bar"
+my\bar(); // calls function "foo\my\bar"
+$a = my\BAR; // sets $a to the value of constant "foo\my\BAR"
+?>