This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 233195 - /* @var */ syntax is not working correctly in the nightly builds
Summary: /* @var */ syntax is not working correctly in the nightly builds
Status: RESOLVED WORKSFORME
Alias: None
Product: php
Classification: Unclassified
Component: Editor (show other bugs)
Version: 7.4
Hardware: All All
: P3 normal (vote)
Assignee: Ondrej Brejla
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-22 15:44 UTC by gena01
Modified: 2013-07-23 14:05 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gena01 2013-07-22 15:44:25 UTC
I have existing code with /* @var $blah \Some\NameSpace\Class */
and $blah shows the wrong type as if the editor is not honoring the @var syntax anymore, also auto-completion is not showing the right completion values because it things that the variable is of unknown or different type.
Comment 1 gena01 2013-07-22 15:46:35 UTC
Just tested the same source code in 7.3 Netbeans and it's working correctly, looks like a regression.
Comment 2 Ondrej Brejla 2013-07-22 17:43:56 UTC
Just tested this piece of code, everything works properly.

<?php
namespace A\B\C;
class TestClass {public $field;}
namespace Another;
/* @var $test \A\B\C\TestClass */
$test-> //CC here
?>

$field is suggested.

Product Version: NetBeans IDE Dev (Build 20130719-020f47e7b89a)
Java: 1.7.0_13; Java HotSpot(TM) 64-Bit Server VM 23.7-b01
Runtime: Java(TM) SE Runtime Environment 1.7.0_13-b20
System: Mac OS X version 10.8.4 running on x86_64; UTF-8; cs_CZ (nb)
Comment 3 gena01 2013-07-23 14:05:22 UTC
This example actually works, very strange.

I have a Symfony 2 Project and somehow it's picking up the type as "Controller" which it's not and showing wrong auto-complete. If i wipe the cache and restart Netbeans i get "NullPointerException" (filed separately) and it shows the same auto-complete again. :(


I'll try to come up with a reproduce-able testcase i can post.