This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: class and type values


Per Bothner wrote:

First, my impression is that some Kawa programmers are
confused by the distinction between standard java.lang.Class
objects, and the more general gnu.bytecode.ClassType objects.
...
This may be surprising to people; at least that is my impression.

So one idea is to change Kawa so that the result of evaluating
  <java.util.Vector>
is a java.lang.Class value, rather than a gnu.bytecode.ClassType value.
Similarly, the name declared by a define-simple-class would be a
j.l.Class value, not a ClassType value.

The principle of least surprise is a strong one, and I endorse the change on that basis. The long sought change so that "Foo" instances are java.lang.String is needed for the same reason.


The buzz around scripting languages is a great opportunity for Kawa ("the best thing for Java that no one has ever heard of") to get some wider adoption. One small item that is worthwhile is adding JSR-223 support:

http://java.sun.com/developer/technicalArticles/J2SE/Desktop/scripting/

I've recently done a little investigation into Groovy (which made its "1.0" release last month) and am quite impressed with its expressive power in minimal syntax. It is worth looking at to see how far Java features can be extended in an integrated fashion (particularly GroovyBeans + MOP and Collections).

http://groovy.codehaus.org/Collections
http://groovy.codehaus.org/Groovy+Categories
http://groovy.codehaus.org/Using+the+Proxy+Meta+Class

Jim


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]