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 2019/10/10 14:57:08 UTC

[GitHub] [netbeans] sharpedavid edited a comment on issue #1247: Inline parameter name hints for Java

sharpedavid edited a comment on issue #1247: Inline parameter name hints for Java
URL: https://github.com/apache/netbeans/pull/1247#issuecomment-540201290
 
 
   > 
   > 
   > It seems this patch only affect literals? Shouldn't it fire for every kind of parameter? Maybe configurable for performance reasons? :)
   
   I bet the thought is that if you're passing in an actual variable, you should just a good variable name. Otherwise you have lots of instances of:
   
   `firstName.substring(beginIndex: beginIndex, endIndex: endIndex);`
   
   Edit: Just to reword, I'm saying that if your variable names are good, these hints would add a lot of screen clutter. I am still interested in this feature, but I am thinking it has some interesting unintended consequences.
   
   ```
   // Example 1: Clutter
   Car car = factory.buildCar(make: carMake, model: carModel);
   car.drive(speed: fastSpeed, destination: nearestArbys)
   
   // Example 2: Cleaner
   Car car = factory.buildCar(carMake, carModel);
   car.drive(fastSpeed, nearestArbys);
   ```
   
   Please don't get too caught up deciding if you prefer example 1 or 2, my point is that it's probably a preference.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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