You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2023/01/20 12:13:16 UTC

[GitHub] [netbeans] frkinta opened a new issue, #5329: [PHP] Netbeans may also check inside used traits to determine if a property is used

frkinta opened a new issue, #5329:
URL: https://github.com/apache/netbeans/issues/5329

   ### Apache NetBeans version
   
   Apache NetBeans 16
   
   ### What happened
   
   private promoted property marked as unused
   
   ### How to reproduce
   
   ```php
   <?php
   
   namespace Test;
   
   class myClass
   {
   
       use myTrait;
   
       public function __construct(
               private Service $Service
       ) { }
   
   }
   
   ```
   ```php
   <?php
   
   namespace Test;
   
   trait myTrait
   {
   
       public function dependancyUsage()
       {
           $this->Service->execute();
       }
   
   }
   
   ```
   In this case, `$Service` is marked as unused inside `myClass` class
   
   ### Did this work correctly in an earlier version?
   
   No / Don't know
   
   ### Operating System
   
   ubuntu 22.04
   
   ### JDK
   
   OpenJDK Runtime Environment (build 17.0.5+8-Ubuntu-2ubuntu122.04) OpenJDK 64-Bit Server VM (build 17.0.5+8-Ubuntu-2ubuntu122.04, mixed mode, sharing)
   
   ### Apache NetBeans packaging
   
   Apache NetBeans provided installer
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit a pull request?
   
   No
   
   ### Code of Conduct
   
   Yes


-- 
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: notifications-unsubscribe@netbeans.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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