Uploaded image for project: 'Drools'
  1. Drools
  2. DROOLS-45

Compilation failure caused by a CCE when building a rule with a unification in the LHS

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 5.5.1.Final, 6.0.0.Alpha9
    • None
    • None
    • None

    Description

      The following DRL doesn't compile and in particular fails with a java.lang.ClassCastException: org.drools.rule.GroupElement cannot be cast to org.drools.rule.Pattern

      declare A
      end
      
      declare B
       inner : A
      end
      
      rule "Init"
      when
      then
        A a = new A();
        insert( a );
        insert( new B( a ) );
      end
      
      rule "Check"
      when
        B( $in := inner )
        $in := A()
      then
      end
      

      Attachments

        Activity

          People

            mfusco@redhat.com Mario Fusco
            mfusco@redhat.com Mario Fusco
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: