My thoughts as an enterprise Java developer.

Thursday, August 02, 2007

Dynamic/static language

What if a language allow both static and dynamic types. That might allow the best of both worlds. i.e.:
String str = "Hello";
var temp = str;
temp = 10;

1. Would that be possible?
2. Would that be beneficial?

1 comment:

James A. N. Stauffer said...

JEP 286: Local-Variable Type Inference is something similar that was slated for Java 1.9 but is no longer in the list.