javac should restrict source file name if class used outside source file

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Duplicate
    • Priority: P4
    • None
    • Affects Version/s: 6
    • Component/s: tools
    • generic
    • solaris_8

      javac should implement the following (optional) JLS 7.6 constraint as a warning:

        When packages are stored in a file system (?7.2.1), the host system may choose to enforce the restriction that it is a compile-time error if a type is not found in a file under a name composed of the type name plus an extension (such as .java or .jav) if either of the following is true:

          * The type is referred to by code in other compilation units of the package in which the type is declared.
      ...

            Assignee:
            Jonathan Gibbons
            Reporter:
            Neal Gafter (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: