News for hackers. Stuff that matters.
Re:Evolving Java Without Changing the Language by mdemare on Wednesday October 21, 2009 @02:25PM (#895302)
I found the part about IDEs fascinating: IntelliJ will recognize those ugly anonymous classes, and show them to you as closures.

I wonder how far you could take this. A language like Duby gives you Ruby syntax, while producing identical bytecode as Java. If you could translate Duby into Java source code, and parse and show it as Duby, your IDE could let you program in Duby without anyone else on your project even noticing.

Then you're in effect relegating Java to object code.

Re:Evolving Java Without Changing the Language by bad_user on Wednesday October 21, 2009 @02:41PM (#895353)
Isn't that what compilers do?

I actually am thinking of writing a compiler for a custom language that will be translated to Java. It will be a lot like C#, but simplified, with a lot of the cruft removed (like the requirement to define a Main class with a static main, or the requirement that all code should be wrapped in a class, but reified generics is something I want although I'm not sure if it's feasible).

I don't like Duby, I don't like Ruby for that matter. Mostly because the syntax is not as extensible as I'd like and because the variables don't have lexical scope.

Re:Evolving Java Without Changing the Language by axod on Wednesday October 21, 2009 @02:45PM (#895359)
I think it's a pretty bad idea. The more IDEs hide code from people, the more verbose code will be produced.

Much easier to just setup a simple macro system to run over source files and replace things before compilation.

Re:Evolving Java Without Changing the Language by eru on Wednesday October 21, 2009 @07:15PM (#895861)
Where's the difference?