incompatible arguments to ? conditional compile with -source 1.4

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P2
    • 5.0
    • Affects Version/s: 5.0
    • Component/s: tools
    • b28
    • generic
    • generic

      This should fail with -source 1.4

      public class test {
         void foo() {
             boolean b = true;
             System.out.println( b ? 0 : false ); //<- int vs. boolean error
      }}

            Assignee:
            Neal Gafter (Inactive)
            Reporter:
            Steve Sides (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: