The Artima Developer Community
Sponsored Link

Weblogs Forum
Java 7: Too Little, Too Late?

64 replies on 5 pages. Most recent reply: Jan 30, 2012 1:07 PM by Steve Carmeli

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 64 replies on 5 pages [ « | 1 ... 2 3 4 5 ]
Bruce Eckel

Posts: 868
Nickname: beckel
Registered: Jun, 2003

Re: Java 7: Too Little, Too Late? Posted: Sep 7, 2011 2:55 PM
Reply to this message Reply
Advertisement
> Is this type noise the major reason why Scala ( and
> other statically typed FPLs ) is perceived difficult?

The problem is that the early adopters cannot resist showing off and being clever by writing ultra-dense code. There are times when terseness is useful, but what these folks don't understand is that -- especially in the early days of a language -- clarity is more important than anything.

Fortunately, Scala can easily be written in a clear manner. You're just not seeing it from the cleverer-than-thou folks.

James Watson

Posts: 2
Nickname: banned
Registered: Sep, 2011

Re: Tools Posted: Sep 9, 2011 2:03 PM
Reply to this message Reply
> > On a side note, while I tend to hate tools that generate
> > java source code, it's good to keep in mind that compilers
> > are tools that generate code.
>
> That is true. I think there is an argument about how
> complex the generated code is. I've never heard of bugs
> in an assembler, but compiler optimizations will cause
> trouble once in a while.

I've been thinking about this because I realized in writing the above response that I didn't have a clear explanation for why I like (love even) compilers but loathe java source code generators.

I what it comes down to is that compilers are designed to generate code that is not fit for human consumption and produce output for machine use. I assert that few people in this day and age would argue that compilers are not a paradigm shifting technology that has fundamentally improved the speed and quality of software development.

So having established that code generation by compilers is a very good thing, why is it that what is good for the goose is not good for the gander? I think it comes down to one general issue: code generators generate code in languages intended for human consumption. The actual code that is produced is often not. A 'true' source code generator is a tool that generates code that is meant for people to work with (e.g. templates). If the code produced is not meant for people, the generator is really acting more like a compiler. I guess that's OK as long as I don't have to see that code.

The problem appears when generators start to blur the lines between source generation and compiling. You can update some parts but not others or you can't touch the source but you must interact with the generated APIs and try to figure out how they relate to the generator inputs.

I also think that some generator tools are just poorly designed or are misguided in their approach. For example, most XML schema-based code generation tools basically generate Java objects based on the structures in the XML. They don't really 'bind' anything. That work is left to the developer to do using lots of tedious coding. In other words, they don't actually provide any solution, they just move the problem into a different language.

Kay Schluehr

Posts: 302
Nickname: schluehk
Registered: Jan, 2005

Re: Tools Posted: Sep 11, 2011 6:33 AM
Reply to this message Reply
> The problem appears when generators start to blur the
> lines between source generation and compiling. You can
> update some parts but not others or you can't touch the
> source but you must interact with the generated APIs and
> try to figure out how they relate to the generator
> inputs.

This might be the reason why IDEs started to serialize widget elements into XML created by GUI designers. The source and the data were finally separated. It didn't took long though before XML became the programming language of choice for GUIs following the model of declarative/imperative hybrids as JSP and ASP. Maybe this evolved even in parallel. WPF XAML and Adobe Flex also adopted this model. It's one of those design decisions which somehow sneaked in, got cloned by many others while being hated with passion [1] by developers.

I guess with the new crop of functional programming languages we'll see that those XML hybrid languages will go away again, simply because they support BNF style "algebraic" data types: naming, tupling ( sequences ), variants ( alternatives ) and recursion - that's all that is needed. Each of them is essentially a mini-grammar and a program processes many, many embedded domain specific languages and there is little need to bolt on XML for this purpose.

[1] http://blog.objectmentor.com/articles/2007/05/17/the-hidiocy-of-xml-languages

Slava Imeshev

Posts: 114
Nickname: imeshev
Registered: Sep, 2004

Re: Java 7: Too Little, Too Late? Posted: Sep 15, 2011 10:02 PM
Reply to this message Reply
To me Java is pretty mature. It's already there and I think Java as a language should be left alone except maybe some polishing enhancements. Java 7 features are nice, small and welcomed additions.

What would benefit from a lot of new stuff is Java SDK. There is a bunch of useful JSRs that have been sitting there for years and it would be great to see them be a part of SDK.

Heck, adding javax.junit and javax.struts would make much more sense than those glorified functors.

Regards,

Slava Imeshev
Cacheonix | Clustered Java Cache
http://www.cacheonix.com

Steve Carmeli

Posts: 1
Nickname: newisrael
Registered: Jan, 2012

Re: Java 7: Too Little, Too Late? Posted: Jan 30, 2012 1:07 PM
Reply to this message Reply
I tire of all these new languages that come up all the time. So many are just a short trend and who can tell which ones will endure / survive to become a really useful language and which ones are just a flash in pants.

I can accept Mr. Eckel's summary analysis that the keepers of Java are resting on their laurels and not keeping up with the changes in language design, but that hardly justifies chasing a new language so readily and easily.

Steve Carmeli

Flat View: This topic has 64 replies on 5 pages [ « | 2  3  4  5 ]
Topic: The Principles of Good Programming Previous Topic   Next Topic Topic: First Impression: Scala Goodies


Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2014 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us