News for hackers. Stuff that matters.
Re:JDK 7 Features by c00p3r on Monday September 20, 2010 @12:50AM (#1707836)
Java is everywhere. Berkeley CS162 course uses Java language to teach OS Design and Internals - they wrote a pseudo-code examples in Java, a-la SaveRegisters(). It is a madness, Isn't it? ^_^
Re:JDK 7 Features by points on Monday September 20, 2010 @06:18AM (#1708320)
Why madness? It has a clear, logical, consistent and easy to understand syntax.
Re:JDK 7 Features by c00p3r on Monday September 20, 2010 @10:08AM (#1708836)
Really? Easier than C syntax, which is a more appropriate in this context, and on which Java's syntax is based upon?
Re:JDK 7 Features by points on Monday September 20, 2010 @11:48AM (#1709232)
Way easier than C syntax. Even though I have long mastered various assembly languages and higher level languages, C pointers and their arithmetic still confuses me.

There's nothing worse than something like bar = *[&foo + 88] or whatever it is.

Re:JDK 7 Features by sid0 on Monday September 20, 2010 @11:27AM (#1709150)
> Really? Easier than C syntax

Significantly easier. Think about all those pointers that simply aren't there now.

> which is a more appropriate in this context

This is a value judgement.

The generally nicer semantics (automatic memory management! proper strings!) are also worth a lot.

Re:JDK 7 Features by sid0 on Monday September 20, 2010 @08:07AM (#1708485)
I'm a TA for an OS course that is closely following the Berkeley CS162 course, down to using Java for assignments. We've had much less trouble than with the C++ we used to use.
Re:JDK 7 Features by c00p3r on Monday September 20, 2010 @10:13AM (#1708863)
Why not a plain C which is an obvious choice? I think I know the answer - "because of a buzz". ^_^

And of course, using a VM-hosted language to describe things which are on two levels of abstraction lower is a little bit funny.

Re:JDK 7 Features by sid0 on Monday September 20, 2010 @11:24AM (#1709142)
> Why not a plain C which is an obvious choice?

Because manual memory management is a PITA.

> And of course, using a VM-hosted language to describe things which are on two levels of abstraction lower is a little bit funny.

Why? As long as you're clear that it's a pedagogical tool, it's perfectly fine. And there are incubation OSes (e.g. Singularity) that are almost entirely managed.

Re:JDK 7 Features by c00p3r on Monday September 20, 2010 @12:14PM (#1709336)
We're talking about simplicity and clarity of language's syntax? Why memory management?

btw, to whom memory management is a PITA?

Re:JDK 7 Features by sid0 on Tuesday September 21, 2010 @04:39PM (#1714040)
> We're talking about simplicity and clarity of language's syntax? Why memory management?

Both the syntax and the semantics are nicer.

> btw, to whom memory management is a PITA?

To anyone who tries to do it. That automatic memory management is easier to program with than manual memory management is self-evident.