News for hackers. Stuff that matters.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @11:19AM (#14401958)
Now, I'm sure Gosling is a much smarter man than me, and I couldn't be a 10th the language designer he was, but I'm going to say something terrible:

Java was badly designed, as a language. The things that made it good came far, far too late in its lifetime. The thing that made it successful was not a good design, but big corporate backing, a free compiler, a batteries-included approach to libraries, good marketing, and good platform support.

But the language itself was bad. No custom copy-by-value objects, static typing without generics or macros to make reusable collections, a GUI library that was widely considered a bad joke, a null hole big enough to drive a truck through, checked exceptions, the frustrating inconsistency between .Equals and ==...

So many bad decisions. Many of these were mitigated over time, but it took a long time to get there. It's hard to say that "designed Java" is really a good feather in the cap.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by nosefouratyou on Tuesday May 23, 2017 @11:24AM (#14402015)
"We were not out to win over the Lisp programmers; we were after the C++ programmers. We managed to drag a lot of them about halfway to Lisp."

- Guy Steele, Java spec co-author

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @11:47AM (#14402193)
Dragged them out to an ocean halfway between two islands, imho.

Custom collections in a statically-typed language without macros or generics or templates is masochism. I was very disappointed back in 2005 that it took competition from Microsoft with .NET 2.0 to force the Java leadership's hand to finally provide that missing feature.

Why even bother with static typing if coders are constantly having to type-cast and null-check everything?

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by pjmlp on Tuesday May 23, 2017 @12:09PM (#14402412)
Sadly those flocking to Go think otherwise, for them Java is already a programming language for advanced developers.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @12:18PM (#14402505)
Go, at least, has a built-in map object.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by pjmlp on Tuesday May 23, 2017 @01:03PM (#14402955)
I fail to see how it is any better than what is available in Java since 1998 (1.2).
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @05:36PM (#14405595)
Go's maps are typed. Java's HashMap (in 1.2) was not.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by candiodari on Tuesday May 23, 2017 @11:24PM (#14407387)
I wonder if it's okay to state it like that, actually. Java's Hashmaps are typed, in the sense that it's implemented using the type system.

Go maps are an explicit exception in the type system. They have their own type rule. And in the syntax. They have multiple map-specific syntax rules (and not just literals). And in the semantics (e.g. using range on them).

Go doesn't have maps, as such. Go has an inbuilt language feature of one particular type of map, that I assume is thought to be good enough for everybody.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by pjmlp on Tuesday May 23, 2017 @05:54PM (#14405701)
Last time I checked, Object was a type.

But if you prefer, advance a few years up to 2004 (1.5), still 5 years before Go was created.

Also HashMap is just one implementation among all of those that are available in the standard library for the Map interface, each one tailored for a specific use case, with regard to performance and memory constraints.

In Go you cannot change the behaviour of that built in hash map.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by nickbauman on Tuesday May 23, 2017 @12:34PM (#14402671)
One word: Clojure.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @12:37PM (#14402705)
Absolutely. The JVM is great, and JVM languages like Kotlin and Clojure. Even modern Java is a good language. I'm not arguing that Java hasn't come into its own as a good language. My point is that the Java I cut my teeth on? "Java 2"? That was bad.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by justicezyx on Tuesday May 23, 2017 @11:29AM (#14402047)
Do not paint a picture with one-sided argument. To say Java is badly designed, is to say human is an evolution failure. It's not hard to find evidences to support both, but they hardly make a dent to both being hugely successful things in their respective fields.

Java is a great and extremely well designed language. All you mentioned are nothing but natural expansion of the language's use cases.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by rubber_duck on Tuesday May 23, 2017 @02:27PM (#14403812)
>Java is a great and extremely well designed language. All you mentioned are nothing but natural expansion of the language's use cases

I'm mostly seeing Java treated like a legacy or a conservative choice - not something I would describe as great. JVM has a lot of quality engineering but there are better languages to leverage that ecosystem.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by bitmapbrother on Tuesday May 23, 2017 @12:12PM (#14402433)
>To say Java is badly designed, is to say human is an evolution failure

I love lines that say so much with so little. Well said.

Java was the right language at the right time. That's why it was so successful.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @12:22PM (#14402547)
> Java was the right language at the right time. That's why it was so successful.

any moderately-usable language with a free, cross-platform compiler and a full batteries-included library for everything and support for every major platform and a major vendor pushing it and the kind of global marketing PR (The Official Programming Language of Canada!) would have seen the same success as Java at the time.

The quality of the language design itself was "passable" at best, but that's all it needed to be with the forces it had pushing it and the market conditions at the time.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by hyperpallium on Tuesday May 23, 2017 @12:49PM (#14402825)
Java is C++ without the broken glass

It's hard to look at a historical success, and determine which attributes caused that success. I agree that the non-product attributes (tooling, docs, libraries, corporate backing etc) were important. Elsewhere you describe it as "moderately-usable", and I think that implies the key: to compare it with the alternatives, such as C++ and COBOL. That's how market success comes about.

It's similar with google: was it "the algorithm"? Or was it honest results, uncluttered, fast?

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by kazinator on Tuesday May 23, 2017 @10:48PM (#14407262)
> Now, I'm sure Gosling is a much smarter man than me

Java doesn't represent anywhere near the full depth of what Gosling actually knows about programming languages. You remark about "static typing without generics or macros to make reusable collection". Yet, Gosling made a structural macro system for the C language in 1989. The ideas in that could easily have been further developed in Java.

From Mock Lisp to Java: the really unfortunate thing about Gosling is the cynicism in his designs.

Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Scarbutt on Tuesday May 23, 2017 @12:22PM (#14402544)
You say all that in hindsight.
Re:James Gosling, the ‘Father of Java,’ joins Amazon Web Ser... by Pxtl on Tuesday May 23, 2017 @12:39PM (#14402719)
I learned Java after learning Python and C++. Even at the time, the combination of static typing and no macros/generics/templates was cringeworthy. Then C# came along with Generics and the Java leadership finally admitted they had a problem.

To be blunt: this is not hindsight. This is me remembering working with Java in the early 2000s. These were things that jumped out at me as an undergrad student as obvious pain-points in a new language I was learning that were not present in other languages I had used.