Hi,

very interesting article. I'm not sure if I should rather ask here or  
in your blog, I'll try here first :-)

In the article you use a function H(Object.equals) in pseudocode,  
which is supposed to give you a method handle. I'm curious, with the  
new uses of annotations for meta programming in Java (using reflection  
or byte code modifications like AspectJ), you'll see stuff like this  
all over the place:

@Entity
@Index(on = "bar")
class Foo {
   private String bar;
}

I.e., the field bar is referenced by it's name as a String, which is  
ugly for many reasons. Stuff like this can be found in Hibernate  
annotations, JPA annotations, JSR-311 and so on.

I think while your at it defining a way to obtain a handle to a  
method, maybe it would be nice to introduce something like a Smalltalk  
symbol to Java? I'd like to be able to write "@Index(on = &Foo.bar)",  
or something similar. We'd need the equivalents of a local symbol  
(resolvable in the context of a class), a resolved symbol that maps to  
a fully qualified name, and then maybe a way to differentiate between  
methods and fields.

Something like this would make many meta programming APIs a lot easier  
to use, including yours about method handles.

Regards,
Martin

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "JVM 
Languages" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/jvm-languages?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to