Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-5057445

javac allows catching type parameter

    Details

    • Subcomponent:
    • Resolved In Build:
      b56
    • CPU:
      generic
    • OS:
      solaris_8

      Description

      javac fails to give the required error on the following code. See also 4992380.

      class J {
          <T extends Error, U extends Error> void foo() {
              try {
                  int i = 12;
              } catch (T ex) {
              } catch (U ex) {
              }
          }
      }

        Attachments

          Activity

            People

            • Assignee:
              ahe Peter Ahe
              Reporter:
              gafter Neal Gafter
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported:
                Indexed: