Order of automatically imported packages and ambiguity

后端 未结 3 1895
醉话见心
醉话见心 2021-01-13 01:39

JLS: Chapter 7. Packages:

A package consists of a number of compilation units (§7.3). A compilation unit automatically has access to all types

3条回答
  •  南方客
    南方客 (楼主)
    2021-01-13 02:35

    I think this is covered in Shadowing & Obscuring in that a package scoped Class takes precedence over a wildcard import.

提交回复
热议问题