You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "dstutz (via GitHub)" <gi...@apache.org> on 2023/10/16 14:36:11 UTC

[I] Formatting bug with record compact constructor [netbeans]

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

   ### Apache NetBeans version
   
   Apache NetBeans 19
   
   ### What happened
   
   If you use the compact constructor of a record and you have 0 or 1 record parameters, NB formatting will put 1 space but from 2+ it will put the number of spaces that you have parameters.
   
   ### How to reproduce
   
   Format this Java:
   
   ```
   public sealed interface Example {
   
       public record TwoSpaces(String one, String two) implements Example {
   
           public TwoSpaces  {
                           ^^
           }
       }
   
       public record ThreeSpaces(String one, String two, String three) implements Example {
   
           public ThreeSpaces   {
                             ^^^
           }
       }
   
       public record FourSpaces(String one, String two, String three, String four) implements Example {
   
           public FourSpaces    {
                            ^^^^
           }
       }
   }
   ```
   
   ### Did this work correctly in an earlier version?
   
   No / Don't know
   
   ### Operating System
   
   Windows 10 64
   
   ### JDK
   
   Temurin jdk-17.0.7.7-hotspot
   
   ### Apache NetBeans packaging
   
   Apache NetBeans binary zip
   
   ### 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: 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


Re: [I] Formatting bug with record compact constructor [netbeans]

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien closed issue #6573: Formatting bug with record compact constructor
URL: https://github.com/apache/netbeans/issues/6573


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

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