User loginNavigation |
archivesReflection in Java: how are they getting with it?
We seem to discuss pretty specific issues lately, so I feel I can bring this one up.
For a PL in which dynamism is one of the selling points, Java has pretty bad support for reflection: reification/introspection/intercession trio. Reification is crippled by fact that not all concepts have representation, accessible to programs - the one for bytecode (literally an array of bytes) is a joke. This can be helped by libraries, though, and indeed is. Introspection is limited - for bytecode as well (a program cannot in general obtain a representation of bytecode for the object at hand). That's a more serious limitation, although there are ways around it if you are willing to make some assumptions. Intercession has another twist - on a positive side, it's possible to obtain classes from bytes (though it was not possible the other way around - funny, eh?), but on a negative side, while introspection had structured representation for some concepts (like fields), intercession knows only byte arrays. Ugh. I will skip my complaints to representation of invocations, call stacks and threads, as the post is already quite negative. To drive this towards PL design: how did Java get there? Was it because in early years there was little use for reflection? Why wasn't it fixed? Is it a scientific problem, an engineering one, or maybe cultural? How can newly designed PLs avoid such a fate? PS: For some users reflection and MOP may be something very esoteric and unpractical, but look at Java "enterprise" open source projects: most of them are just grown from one or other attempt to overcome these deficiencies of the language. Unfortunately, there is a limit on what libraries can do to a PL. According to Allen Holub programming is now a liberal art. When did this happen?Allen Holub has written an article explaining quite clearly why neither programming nor computer science is a science. He also does an excellent job of explaining why software engineering is an oxymoron. So far he's preaching to the choir.
In what ways would members of LtU change undergraduate curricula in what is now called computer science if you had the power? Perl6 - PUGSWell there doesn't seem to be a plethora of Perl fans here (I hear Python this and Ruby that...) but I thought I'd mention Pugs. Pugs is an implementation of Perl6, written in Haskell. While, as mentioned in other recent articles some languages are moving away from powerful abstractions, Perl continues to suck them in. One of the more interesting things they are putting into Perl6 are junctions (which I like to think of as quantum superpositions). Things like that, along with formalization of the object system and other cleanups should make Perl6 a language which gets mentioned here much more often. The Pugs implementation (in progress) is being written at breathtaking speed. Check it out and lets hear your thoughts! |
Browse archivesActive forum topics |
Recent comments
22 weeks 12 hours ago
22 weeks 16 hours ago
22 weeks 16 hours ago
44 weeks 1 day ago
48 weeks 3 days ago
50 weeks 1 day ago
50 weeks 1 day ago
1 year 4 days ago
1 year 5 weeks ago
1 year 5 weeks ago