aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzzhongwei2012-12-04 02:40:56 (EST)
committerzzhongwei2012-12-04 02:40:56 (EST)
commitab69128c475baf48dbdf864fc46e4c3c6f574009 (patch)
tree55e81f96be4a98f3889dcde90d7a0d0c3a1dad95
parent720de972a2ab956c74d801852cc02ff1a2d27267 (diff)
downloadorg.eclipse.pdt-ab69128c475baf48dbdf864fc46e4c3c6f574009.zip
org.eclipse.pdt-ab69128c475baf48dbdf864fc46e4c3c6f574009.tar.gz
org.eclipse.pdt-ab69128c475baf48dbdf864fc46e4c3c6f574009.tar.bz2
386276: @var second declaration breaking previous declaration
https://bugs.eclipse.org/bugs/show_bug.cgi?id=386276
-rw-r--r--tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc8.pdtt18
-rw-r--r--tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc9.pdtt19
2 files changed, 37 insertions, 0 deletions
diff --git a/tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc8.pdtt b/tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc8.pdtt
new file mode 100644
index 0000000..4aab574
--- /dev/null
+++ b/tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc8.pdtt
@@ -0,0 +1,18 @@
+--TEST--
+Test PHPDoc Function Return Type
+--FILE--
+<?php
+class T1{
+ function test(){
+ /* @var $t2 T2 */
+ $t2->| //... not works, cause of new bug (even if T2 class declared below), this part was working previously
+ }
+}
+class T2{
+ function test(){
+ $t1->
+ }
+}
+?>
+--EXPECT--
+method(test)
diff --git a/tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc9.pdtt b/tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc9.pdtt
new file mode 100644
index 0000000..666545f
--- /dev/null
+++ b/tests/org.eclipse.php.core.tests/workspace/codeassist/php5/testPHPDoc9.pdtt
@@ -0,0 +1,19 @@
+--TEST--
+Test PHPDoc Function Return Type
+--FILE--
+<?php
+class T1{
+ function test(){
+ /* @var $t2 T2 */
+ $t2->| //... not works, cause of new bug (even if T2 class declared below), this part was working previously
+ }
+}
+class T2{
+ function test(){
+ /* @var $t1 T1 */
+ $t1->
+ }
+}
+?>
+--EXPECT--
+method(test)