Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8034048

javac crash with method references plus lambda plus var args

    XMLWordPrintable

Details

    • b04
    • Verified

    Backports

      Description

        This code provokes a javac crash:

        public interface Null {
            @SafeVarargs
            public static <INPUT, OUTPUT> OUTPUT functional(INPUT... input) {
                return null;
            }

            // Uncomment to successfully compile in JDK8 b121 Win32
            // public static <INPUT, OUTPUT> OUTPUT functional(INPUT input) {
                // return null;
            // }

            public static <OBJECT> void main(String... arguments) {
              java.util.function.Supplier<java.util.function.Consumer<OBJECT>> functional = () -> Null::functional;
            }
        }

        reported by srborlongan@gmail.com in lambda-dev

        Attachments

          Issue Links

            Activity

              People

                pgovereau Paul Govereau (Inactive)
                vromero Vicente Arturo Romero Zaldivar
                Votes:
                0 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: