Uploaded image for project: 'CDI Specification Issues'
  1. CDI Specification Issues
  2. CDI-391

Type variable always has an upper bound

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Obsolete
    • Icon: Major Major
    • None
    • 1.1.FD
    • Resolution
    • None

      The specification says:

      the required type parameter is an actual type, the bean type parameter is a type variable and the actual type is assignable from
      the upper bound, if any, of the type variable, or

      or

      the required type parameter is an actual type, the bean type parameter is a type variable and the actual type is assignable to
      the upper bound, if any, of the type variable, or

      depending on the version of the specification. These if any constructs are redundant since JLS defines that every type variable has an upper bound. Even if one is not explicitly declared, java.lang.Object is assumed as the upper bound. This fits the CDI rules well.

      http://docs.oracle.com/javase/specs/jls/se7/html/jls-4.html#jls-4.4

              Unassigned Unassigned
              rhn-engineering-jharting Jozef Hartinger
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: