8012961: Do not restrict static interface methods to be private

Tue, 23 Apr 2013 08:12:14 -0700

author
bharadwaj
date
Tue, 23 Apr 2013 08:12:14 -0700
changeset 4969
ce6d7e43501c
parent 4968
cc12becb22e7
child 4970
1ea6a35dcbe5

8012961: Do not restrict static interface methods to be private
Summary: Lambda changes; spec 0.6.2 - remove the restriction that was added as part of recent changes made to support upcoming changes to compilation of lambda methods.
Reviewed-by: dholmes, acorn

src/share/vm/prims/methodHandles.cpp file | annotate | diff | comparison | revisions
     1.1 --- a/src/share/vm/prims/methodHandles.cpp	Sun Apr 21 21:05:02 2013 -0700
     1.2 +++ b/src/share/vm/prims/methodHandles.cpp	Tue Apr 23 08:12:14 2013 -0700
     1.3 @@ -192,9 +192,8 @@
     1.4      flags |= IS_CONSTRUCTOR | (JVM_REF_invokeSpecial << REFERENCE_KIND_SHIFT);
     1.5    } else if (mods.is_static()) {
     1.6      flags |= IS_METHOD | (JVM_REF_invokeStatic << REFERENCE_KIND_SHIFT);
     1.7 -     // Check if this method is a lambda method that is generated as
     1.8 -     // private static method.
     1.9 -     if (m->is_private() && m->method_holder()->is_interface()) {
    1.10 +     // Get vindex from itable if method holder is an interface.
    1.11 +     if (m->method_holder()->is_interface()) {
    1.12         vmindex = klassItable::compute_itable_index(m);
    1.13       }
    1.14    } else if (receiver_limit != mklass &&

mercurial