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.
Some variables passed to built-in (and custom) functions are set by the function (output parameters) and don't need to be initialized before the call. A prime example is preg_match: if (preg_match('/foo/', 'the foobar', $matches) { ... } Here, any value given to $matches before the call will be overwritten by the call itself, i.e., the call is guaranteed to initialize the variable. IDEA Since there's no way to declare this in PHP, use a simple inline comment in the NetBeans-supplied header files and make this available to custom code as well: function preg_match ( $pattern, $subject, /* out */ array &$matches = null, $flags = 0, $offset = 0 ) {}
*** This bug has been marked as a duplicate of bug 204589 ***