This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Since a Java source file must contain a package declaration as the first token other than comments and whitespace, it should not be difficult to make the package name scanning more robust than it is --i.e. actually build a simple but correct tokenizer which only recognizes whitespace, comment delimiters, `package`, and package names; when it encountered anything other than these (e.g. import, cla ss decl), abort at once. Currently it might be confused about a package decl occurring within a comment block or something, In practice this is likely to be pretty rare.
Verified in dev 200304020100.
Resolved for 3.4.x or earlier, no new info since then -> closing.