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

   ### Apache NetBeans version
   
   Apache NetBeans 29
   
   ### What happened
   
   Steps to Reproduce:
   
   In a runModificationTask, create a ClassTree using make.Class where the 
ModifiersTree contains the RECORD flag (bit 61) or parse a record string using 
TreeUtilities.parseTypeDecls.
   Verify tree.getKind() returns Tree.Kind.RECORD.
   Verify tree.toString() incorrectly renders the keyword as class.
   Commit the change using wc.rewrite(oldParent, updatedParent).
   
   Result: The record is written to the source file as a class, losing its 
record semantics and converting components to fields.
   
   Expected: The keyword record should be used if getKind() == RECORD.
   
   ### Language / Project Type / NetBeans Component
   
   Java Maven Project
   
   ### How to reproduce
   
   
   In a runModificationTask, create a ClassTree using make.Class where the 
ModifiersTree contains the RECORD flag (bit 61) or parse a record string using 
TreeUtilities.parseTypeDecls.
   Verify tree.getKind() returns Tree.Kind.RECORD.
   Verify tree.toString() incorrectly renders the keyword as class.
   Commit the change using wc.rewrite(oldParent, updatedParent).
   
   
   ### Did this work correctly in an earlier version?
   
   No / Don't know
   
   ### Operating System
   
   ubuntu
   
   ### JDK
   
   25
   
   ### Apache NetBeans packaging
   
   Community provided installer
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit a pull request?
   
   No


-- 
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