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

Type checker fails with internal error for diamond

    XMLWordPrintableJSON

Details

    Description

      class Foo<T>{  Foo(T a, T b){} }
      @groovy.transform.CompileStatic
      def bar() {
          Foo<Object> f = new Foo<>("a", new Object())
      }
      bar()

      fails with an internal error, even though it should have passed

      Attachments

        Activity

          People

            blackdrag Jochen Theodorou
            blackdrag Jochen Theodorou
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 0.5h
                0.5h