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

Add lint check for calling overridable methods from a constructor

    XMLWordPrintable

Details

    • b15
    • generic
    • generic

    Description

      One of the coding guidelines from "Effective Java" and elsewhere is to not call overridable methods from a constructor. A compiler is an in excellent position to perform this kind of check.

      The Java Specialists newsletter reports instance of this coding pattern in the JDK codebase:

          www.javaspecialists.eu/archive/Issue210.html

      Attachments

        Issue Links

          Activity

            People

              acobbs Archie Cobbs
              darcy Joe Darcy
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: