[jboss-jira] [JBoss JIRA] Created: (JBRULES-2177) CLONE -NPE in compiler for fact class w/o getters/setters

Neil Wallace (JIRA) jira-events at lists.jboss.org
Tue Jul 7 10:05:03 EDT 2009


CLONE -NPE in compiler for fact class  w/o getters/setters
----------------------------------------------------------

                 Key: JBRULES-2177
                 URL: https://jira.jboss.org/jira/browse/JBRULES-2177
             Project: JBoss Drools
          Issue Type: Bug
      Security Level: Public (Everyone can see)
          Components: drools-compiler (expert)
    Affects Versions: 5.0.0.CR1
         Environment: any
            Reporter: Neil Wallace
            Assignee: Edson Tirelli
             Fix For: 5.0.1.FINAL


A class with missing getters and setters, e.g.:
 public class Command {
	protected String  ident;
	protected Code    code;
	protected boolean refused;
	protected String  reason;
    public Command( String id, Code c ){
    	ident = id;
    	code  = c;
    }
}

used in a rule pattern such as, e.g.:
rule cleanupRefused
    when
        $c : Command( $i : ident, refused == true, $r : reason )
    then
        # whatever
end 

causes a NPE in Declaration:239 due to Declaration.readAccessor == null

This should produce a compiler error message.

NOTICE: Javadoc on constructors of class Declaration is incorrect!


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list