See you at JVMLS

Brian Goetz brian.goetz at oracle.com
Tue Aug 18 21:39:19 UTC 2015


I'll sidestep your clever question by pointing out that the left operand 
of an instanceof check is an expression, not a type.

If you have:

     Foo<any> f = ...

     if (f instanceof Bar) { ... }

this works just fine, because all instantiations of Foo<T> are 
represented by classes whose supertype is Bar.  The harder question is 
the reflective one (Class.isAssignableFrom.)  But reflection is still a 
work in progress (as is the whole thing, of course.)

On 8/18/2015 5:30 PM, Palo Marton wrote:
> Thanks. I have just watched your talk on Valhalla. Just one curious
> question on xxx$any interfaces: How do you handle this?
>
> class Foo<any T> extends Bar { }
>
> Foo$any instanceof Bar?
> On ut, 18. aug 2015 at 19:02 Brian Goetz <brian.goetz at oracle.com
> <mailto:brian.goetz at oracle.com>> wrote:
>
>     JVMLS talks up at:
>     https://www.youtube.com/user/java
>
>
>     On 8/8/2015 12:05 PM, Brian Goetz wrote:
>      > I'll be doing a talk on the path from Model 1 to Model 2 (and a
>     glimpse
>      > of Model 3) at JVMLS next week.  Hope to see some of you there.
>     Videos
>      > should go up on the Java YouTube channel fairly quickly after the
>      > conference.
>      >
>      > In the meantime ... I'll just note that we've had 50+ messages on the
>      > various "Model 2" threads and none of them started with "I tried
>     it out
>      > and..."
>      >
>      > So a reminder ... the most valuable input the community can give
>     in this
>      > process is to provide *actual experience reports*.  That's the main
>      > reason we make the significant investment in making the code and
>     design
>      > sketches available early -- so that people can actually try it
>     out, and
>      > help us see the holes that we might have missed.
>      >
>      >
>
> --
> Pavol Marton



More information about the valhalla-dev mailing list