[jboss-jira] [JBoss JIRA] Updated: (JBRULES-2938) Naming a Java Class the Same as a Package Causes Compile Errors
Matt Fowler (JIRA)
jira-events at lists.jboss.org
Mon Apr 4 15:37:33 EDT 2011
[ https://issues.jboss.org/browse/JBRULES-2938?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Matt Fowler updated JBRULES-2938:
---------------------------------
Steps to Reproduce:
1) Create a rule file under the package service.offer that imports the package service.* and service.offer.*
2) Create a java class under the service package called Offer.java.
The following error occurs while attempting to add the rule file to the knowledge base :
/service/offer/Rule_MyTestRule_0.java (2:153) : The import service.offer cannot be resolved
Renaming the Offer class to something else seems to resolve the issue.
was:
1) Create a rule file under the package a.b that imports the package service.* and service.offer.*
2) Create a java class under the service package called Offer.java.
The following error occurs while attempting to add the rule file to the knowledge base :
/service/offer/Rule_MyTestRule_0.java (2:153) : The import service.offer cannot be resolved
Renaming the Offer class to something else seems to resolve the issue.
> Naming a Java Class the Same as a Package Causes Compile Errors
> ---------------------------------------------------------------
>
> Key: JBRULES-2938
> URL: https://issues.jboss.org/browse/JBRULES-2938
> Project: Drools
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: drools-compiler
> Affects Versions: 5.1.0.FINAL
> Reporter: Matt Fowler
> Assignee: Mark Proctor
>
> Creating a class with the same name as a package which is imported in a drools rule file causes compilation errors.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list