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

Truncated error message with Incompatible : null

XMLWordPrintable

    • b11
    • x86_64
    • generic
    • Verified

      FULL PRODUCT VERSION :
      java version "10" 2018-03-20
      Java(TM) SE Runtime Environment 18.3 (build 10+46)
      Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10+46, mixed mode)

      ADDITIONAL OS VERSION INFORMATION :
      Microsoft Windows [Version 10.0.16299.334]

      A DESCRIPTION OF THE PROBLEM :
      1. Compile testcase
      2. Exception thrown:

      error: incompatible types: bad return type in lambda expression
              return () -> test().thenCompose(value -> {
          null

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      The error message should indicate that the lambda was expected to return a CompletionStage<Integer> but instead it returned a Supplier<CompletionStage<Integer>>
      ACTUAL -
      Error message cut off with "null" apparently due to an internal error

      REPRODUCIBILITY :
      This bug can be reproduced always.

            vromero Vicente Arturo Romero Zaldivar
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: