fix clang compilation (Denys Duchier).
This commit is contained in:
parent
0ed4e15925
commit
e938c17748
@ -119,11 +119,7 @@ public:
|
|||||||
|
|
||||||
// -- use this function instead:
|
// -- use this function instead:
|
||||||
template<class V>
|
template<class V>
|
||||||
friend Clause* Clause_new(const V& ps, bool learnt = false) {
|
friend Clause* Clause_new(const V& ps, bool learnt = false);
|
||||||
assert(sizeof(Lit) == sizeof(uint32_t));
|
|
||||||
assert(sizeof(float) == sizeof(uint32_t));
|
|
||||||
void* mem = malloc(sizeof(Clause) + sizeof(uint32_t)*(ps.size()));
|
|
||||||
return new (mem) Clause(ps, learnt); }
|
|
||||||
|
|
||||||
int size () const { return size_etc >> 3; }
|
int size () const { return size_etc >> 3; }
|
||||||
void shrink (int i) { assert(i <= size()); size_etc = (((size_etc >> 3) - i) << 3) | (size_etc & 7); }
|
void shrink (int i) { assert(i <= size()); size_etc = (((size_etc >> 3) - i) << 3) | (size_etc & 7); }
|
||||||
@ -147,6 +143,12 @@ public:
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
template<class V>
|
||||||
|
Clause* Clause_new(const V& ps, bool learnt) {
|
||||||
|
assert(sizeof(Lit) == sizeof(uint32_t));
|
||||||
|
assert(sizeof(float) == sizeof(uint32_t));
|
||||||
|
void* mem = malloc(sizeof(Clause) + sizeof(uint32_t)*(ps.size()));
|
||||||
|
return new (mem) Clause(ps, learnt); }
|
||||||
/*_________________________________________________________________________________________________
|
/*_________________________________________________________________________________________________
|
||||||
|
|
|
|
||||||
| subsumes : (other : const Clause&) -> Lit
|
| subsumes : (other : const Clause&) -> Lit
|
||||||
|
Reference in New Issue
Block a user