junichi11 opened a new pull request, #6873:
URL: https://github.com/apache/netbeans/pull/6873

   - [#6701](https://github.com/apache/netbeans/issues/6701)
   - https://wiki.php.net/rfc/marking_overriden_methods
   
   ### Fix the Overriding Methods feature 
   
   - Don't handle private methods as overridden/overriding methods
   - Handle also methods of Enum
   - Improve results of unit tests
   - Add/Fix unit tests
   
   ### PHP 8.3 Support: Marking overridden methods (#[\Override]) (Part 1)
   
   - Add the `hasOverrideAttribute()` method to the `PhpVersion`
   - Add the `AddOverrideAttributeHint`
   - Add unit tests
   - Increment spec versions
   
   
![nb-php83-override-attribute](https://github.com/apache/netbeans/assets/738383/8091e4d7-b6e5-4175-a9f5-e905f70691a4)
   
   Note:
   If some trait methods have `#[\Override]`, we should also check wheter the 
parent class has them.
   However, attributes are not indexed at the moment. So, we should improve the 
indexer.
   (Currently, the following case is not supported.)
   
   e.g.
   ```php
   trait T {
       #[\Override]
       public function traitMethod(): void {}
   }
   class C {
       // Fatal error:  C::traitMethod() has #[\Override] attribute, but no 
matching parent method exists
       use T;
   }
   ```
   
   ### PHP 8.3 Support: Marking overridden methods (#[\Override]) (Part 2)
   
   - Fix the code generator, code completion, and 
`ImplementAbstractMethodsHintError`
   - Add/Fix unit tests
   
   Code Generator:
   
   
![nb-php83-override-attribute-codegen](https://github.com/apache/netbeans/assets/738383/e97945f4-85cd-47e2-ab03-58bbe9876649)
   
   Code Completion:
   
   
![nb-php83-override-attribute-cc](https://github.com/apache/netbeans/assets/738383/586ba189-a63a-473c-ac40-a7e69eeeb75d)
   
   Hint:
   
   
![nb-php83-override-attribute-hint](https://github.com/apache/netbeans/assets/738383/7e298b88-5a2e-4263-931b-b55c2899fb66)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to