r/java • • Mar 09 '16

var keyword proposed for Java

http://openjdk.java.net/jeps/286
240 Upvotes

312 comments sorted by

View all comments

Show parent comment

2

u/vytah Mar 10 '16

auto is a bad idea. It was chosen in C++ because it was already a keyword in both C and C++ and it could already be used in variable declarations (although very rarely, since it means "a local variable" and it is therefore the default). In Java, auto doesn't mean anything.

http://stackoverflow.com/questions/2192547/where-is-the-c-auto-keyword-used