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.
Hi, When editing Java, copy pasting codes between two files auto import the "import" statements at the beginning of the file. This feature could be ported to PHP and copy pasting code with classes could automatically add the "use" statement to the file. Example: FILE A: <?php use Foo\Bar; class A { protected $member; function __construct() { $this->member = new Bar(); } } FILE B: <?php class B { } ?> I select the constructor and copy it, and paste it in the class B in file B. Result is : <?php class B { function __construct() { $this->member = new Bar(); } } So it does not work. EXPECTED result : <?php use Foo\Bar; class B { function __construct() { $this->member = new Bar(); } } This issue is like #155422 but for PHP. Thanks