Uploaded image for project: 'Weld'
  1. Weld
  2. WELD-1492

Producers with parameterized return types with a nested parameterized type containing a wildcard or type variable are not detected as invalid

    Details

      Description

      Weld does not report a definition error for the following producers:

      @Produces Bar<Foo<?>> wildcardFooBarProducerField;
      @Produces Bar<Foo<?>> produceWildcardFooBar() { ... }
      @Produces @RequestScoped Bar<Foo<T>> typedFooBarProducerField;
      @Produces @RequestScoped Bar<Foo<T>> produceTypedFooBar() { ... };
      

      But it does report the error for simple(r) producers:

      @Produces Foo<?> wildcardFooProducerField;
      @Produces Foo<?> produceWildcardFoo() { ... }
      @Produces @RequestScoped Foo<T> typedFooProducerField;
      @Produces @RequestScoped Foo<T> produceTypedFoo() { ... };
      

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  luksa Marko Luksa
                  Reporter:
                  luksa Marko Luksa
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: