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.

Bug 268577 - False alert when package private inner class used
Summary: False alert when package private inner class used
Status: NEW
Alias: None
Product: java
Classification: Unclassified
Component: Compiler (show other bugs)
Version: 8.1
Hardware: PC Linux
: P3 normal (vote)
Assignee: Dusan Balek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-10-19 02:49 UTC by pekarna
Modified: 2016-10-19 02:50 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pekarna 2016-10-19 02:49:38 UTC
I have a setup like this:


----------------------------------
TypeScriptGenerator.java:

...

abstract class ModelMember
{
    String beanPropertyName;
    ModelType type;
    boolean isIterable;
    EnumSet<BeanMethodType> methodsPresent = EnumSet.noneOf(BeanMethodType.class);

    public static enum BeanMethodType { GET, SET, ADD, REMOVE; }
}

----------------------------------
TsGenUtils.java:

public class TsGenUtils
static String removePrefixAndSetMethodPresence(String name, String prefix, EnumSet<ModelMember.BeanMethodType> methodsPresent, ModelRelation.BeanMethodType flagToSetIfPrefixFound) { ... }

----------------------------------

NetBeans show an errorneous warning at ModelMember and ModelRelation which are both accessible as package private abstract classes in a class in the same package. It compiles fine.

OpenJDK 1.8, -source 1.8, Maven 3.0.3.
Comment 1 pekarna 2016-10-19 02:50:47 UTC
The warning is
"package ModelMember does not exist"