Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-4295

Joint compilation fails for interfaces with primitive fields

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.8-beta-1
    • 1.7.4, 1.8-beta-1
    • Compiler
    • None

    Description

      Try to joint-compile the following Groovy interface:

      interface Bar {
        int bar = 42
      }
      

      Output:

      Compile error during compilation with javac.
      /var/folders/ak/akL02VQpE-qytx-wR1FH3++++TI/-Tmp-/groovy-generated-7418703305781250498-java-source/Bar.java:10: incompatible types
      found   : <nulltype>
      required: int
      int bar = null;
                ^
      1 error
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            pniederw Peter Niederwieser
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: