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

ClassFormatError when defining two identical methods in the same class

    XMLWordPrintableJSON

Details

    Description

      When by error I created a class with two exact same methods, the class was compiled, however, when run, a ClassFormatError was thrown:

      Caught: java.lang.ClassFormatError: GroovyShellSamplesTest (Repetitive method name/signature)

      A simple class like that will yield the error:

      class FooFooTest extends GroovyTestCase {
      void foo() {}
      void foo() {}
      }

      Ideally, we should get a nice error message when compiling the class

      Attachments

        Activity

          People

            blackdrag Jochen Theodorou
            guillaume Guillaume Sauthier
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: