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

5

u/stepancheg Mar 09 '16

var would be a nice small addition, but are we going to have async/await anytime soon? Writing asynchronous code without some form of coroutines is pain (yes, I'm aware of quasar, which I use, although it has numerous problems).

5

u/hotel77 Mar 10 '16

Just out of curiosity, what are quasars "numerous" problems? I'd love to read and understand more opinions about those.

3

u/stepancheg Mar 10 '16 edited Mar 10 '16

Performance, need for an agent, heavy reliance on JDK internals, somewhat incorrect handling of thread locals to name a few.

Edit: to be clear, quasar people made the best they could do with JDK.

1

u/[deleted] Mar 10 '16

so... stay far away?

1

u/stepancheg Mar 11 '16

In certain use cases it is more suitable than tons of CompletableFutures.