Merging with branch scratch and cleaning the code
[satune.git] / src / Encoders / naiveencoder.cc
index ace03131718e8e35b9a6d4f855eb656f5dc33183..7e33c1b26ca8fd307a4235c37891f3dd2fedde00 100644 (file)
@@ -28,7 +28,7 @@ void naiveEncodingConstraint(Boolean *This) {
                return;
        }
        case ORDERCONST: {
-               if(((BooleanOrder *) This)->order->encoding.type == ORDER_UNASSIGNED)
+               if (((BooleanOrder *) This)->order->encoding.type == ORDER_UNASSIGNED)
                        ((BooleanOrder *) This)->order->setOrderEncodingType(PAIRWISE);
                return;
        }
@@ -65,6 +65,9 @@ void naiveEncodingPredicate(BooleanPredicate *This) {
 void naiveEncodingElement(Element *This) {
        ElementEncoding *encoding = This->getElementEncoding();
        if (encoding->getElementEncodingType() == ELEM_UNASSIGNED) {
+               if(This->type != ELEMCONST){
+                       model_print("INFO: naive encoder is making the decision about element %p....\n", This);
+               }
                encoding->setElementEncodingType(BINARYINDEX);
                encoding->encodingArrayInitialization();
        }