Added dummy expression to check that with removed double negations, expressions are still correctly normalized.

This commit is contained in:
2016-09-02 18:32:13 +02:00
parent 1a96c3ec72
commit 4fb2c331f3
4 changed files with 82 additions and 6 deletions

View File

@@ -81,6 +81,7 @@ class Expression
At,
Binary,
Constant,
Dummy,
Either,
Imply,
Not,
@@ -89,7 +90,7 @@ class Expression
Predicate,
PrimitiveType,
Unsupported,
Variable
Variable,
};
public:

View File

@@ -0,0 +1,38 @@
#ifndef __PLASP__PDDL__EXPRESSIONS__DUMMY_H
#define __PLASP__PDDL__EXPRESSIONS__DUMMY_H
#include <plasp/pddl/Expression.h>
namespace plasp
{
namespace pddl
{
namespace expressions
{
////////////////////////////////////////////////////////////////////////////////////////////////////
//
// Dummy
//
////////////////////////////////////////////////////////////////////////////////////////////////////
class Dummy: public ExpressionCRTP<Dummy>
{
public:
static const Expression::Type ExpressionType = Expression::Type::Dummy;
bool isNormalized() const;
ExpressionPointer normalize() override;
private:
bool m_isNormalized = false;
};
////////////////////////////////////////////////////////////////////////////////////////////////////
}
}
}
#endif