forked from Mirrors/openclonk
Remove a bit of dead code from C4Value
parent
d81c93b7d4
commit
b7ecc49a02
|
@ -16,7 +16,6 @@
|
|||
#ifndef INC_C4Value
|
||||
#define INC_C4Value
|
||||
|
||||
#include "C4Id.h"
|
||||
#include "C4StringTable.h"
|
||||
|
||||
// C4Value type
|
||||
|
@ -107,8 +106,6 @@ public:
|
|||
C4AulFunc *_getFunction() const { return Data.Fn; }
|
||||
C4PropList *_getPropList() const { return Data.PropList; }
|
||||
|
||||
// Template versions
|
||||
|
||||
bool operator ! () const { return !GetData(); }
|
||||
inline operator const void* () const { return GetData() ? this : 0; } // To allow use of C4Value in conditions
|
||||
|
||||
|
@ -233,9 +230,6 @@ inline C4Value C4VFunction(C4AulFunc * pFn) { return C4Value(pFn); }
|
|||
C4Value C4VString(StdStrBuf strString);
|
||||
C4Value C4VString(const char *strString);
|
||||
|
||||
#define C4VFalse C4VBool(false)
|
||||
#define C4VTrue C4VBool(true)
|
||||
|
||||
extern const C4Value C4VNull;
|
||||
|
||||
// C4Values can contain data structures that have to maintain their
|
||||
|
|
|
@ -63,6 +63,6 @@ TEST_F(AulMathTest, Bug1389)
|
|||
EXPECT_EQ(C4VINT_MAX, RunExpr("-2147483648 - 1"));
|
||||
// x ± 1 ± 1 is handled differently from x ± 2, yet the result should be
|
||||
// the same.
|
||||
EXPECT_EQ(C4VTrue, RunExpr("2147483647 + 1 + 1 == 2147483647 + 2"));
|
||||
EXPECT_EQ(C4VTrue, RunExpr("-2147483648 - 1 - 1 == -2147483648 - 2"));
|
||||
EXPECT_EQ(C4Value(true), RunExpr("2147483647 + 1 + 1 == 2147483647 + 2"));
|
||||
EXPECT_EQ(C4Value(true), RunExpr("-2147483648 - 1 - 1 == -2147483648 - 2"));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue