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

Immutable fails with defaults=true

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.5.19, 3.0.13, 4.0.6
    • 4.0.7
    • None
    • None

    Description

      Consider the following:

      @Immutable(defaults=true, noArg=false)
      class Foo {
        String bar, baz
      }
      

      If "noArg=false" is removed there is a compiler error "Unable to compile class Foo due to hash collision in constructors".

      Attachments

        Issue Links

          Activity

            People

              emilles Eric Milles
              emilles Eric Milles
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: