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.
Please extend syntax highlighting for documentation keywords to simple comments: /* @var $abc TYPE */ support for @var is already implemented (http://netbeans.org/bugzilla/show_bug.cgi?id=156212) also having TYPE in different color would be nice. Thanks
I add two points with phpdoc /* @var */ First it's just a problem of syntax coloration. In your documentation (http://netbeans.org/kb/docs/php/editorguide.html) you use /* @var $variable Object */ to define a variable as an object. But when I write this in my netbeans (6.9.1) "@var" not appear in bold, on the other hand when I write /** @var $variable Object */ "@var" is in bold. The real syntax is /* @var $variable Object */ (like in your documentation) not /** @var $variable Object */ with two ** the completion doesn't work. So the problem is just the "@var" is not in bold with the real syntax. It's not very important but I underline this point. The second problem is more important for me. I use two class for exemple, Object1 and Object2 class Object1 { public $var1; public $var2; } class Object2 { /* @var $objectOne Object1 */ public $objectOne; public $var3; } In the second class I declare the variable $objectOne like an object Object1 with your phpDoc syntax. If in the class I write in a function : $this->objectOne-> objectOne is not considered as an object and Netbeans doesn't propose completion. But if I write: $objectOne-> it's work and NetBeans propose var1 and var2. So with $this it's doesn't work but without yes. It's Strange. So when I use a object Object2 in my project, I never have the autocompletion for the field objectOne. Thanks (In reply to comment #0) > Please extend syntax highlighting for documentation keywords to simple > comments: > > /* @var $abc TYPE */ > > support for @var is already implemented > (http://netbeans.org/bugzilla/show_bug.cgi?id=156212) also having TYPE in > different color would be nice. > > Thanks
For class fields, you have to use classic PHPDoc format /** @var Type */. VARDoc type is used just "inline" for a virtually defined types...when NetBeans can't infer a proper type. And @var is bold in 7.3 even in VarDoc type ;)