-
Notifications
You must be signed in to change notification settings - Fork 918
Open
Labels
PHP[ci] enable extra PHP tests (php/php.editor)[ci] enable extra PHP tests (php/php.editor)kind:bugBug report or fixBug report or fixneeds:triageRequires attention from one of the committersRequires attention from one of the committers
Description
Apache NetBeans version
Apache NetBeans 28
What happened
When using the ‘generate override’ feature on a class that extends another class, and selecting the constructor, it is created by also assigning the return type, which is not permitted for a constructor.
Language / Project Type / NetBeans Component
PHP project
How to reproduce
- In a PHP project, create a class that extends another class.
- Right-click on the editor and select ‘Insert code’ to bring up the “Generate” menu, then select ‘Override & implement methods’.
- Select "__constructor", then press "Ok" button
- The constructor with return type is generated.
Did this work correctly in an earlier version?
No / Don't know
Operating System
Arch Linux
JDK
jdk21-openjdk
Apache NetBeans packaging
Community provided installer
Anything else
- The error shown in the screenshot was generated when running PHP version 8.3, but the same error also occurs in version 8.4.
- The bug does not occur when ‘Constructor’ is selected in the same ‘Generate’ menu.
Are you willing to submit a pull request?
No
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
PHP[ci] enable extra PHP tests (php/php.editor)[ci] enable extra PHP tests (php/php.editor)kind:bugBug report or fixBug report or fixneeds:triageRequires attention from one of the committersRequires attention from one of the committers