summaryrefslogtreecommitdiff
path: root/zend/constantimpl.h
diff options
context:
space:
mode:
Diffstat (limited to 'zend/constantimpl.h')
-rw-r--r--zend/constantimpl.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/zend/constantimpl.h b/zend/constantimpl.h
index 1fb1676..46a16d2 100644
--- a/zend/constantimpl.h
+++ b/zend/constantimpl.h
@@ -127,13 +127,9 @@ public:
break;
case IS_LONG:
-#ifdef PHPCPP_32BIT
- // 32bit systems find this difficult
- clss.property(_name, (int32_t)Z_LVAL(_constant.value), Php::Const);
-#else
- // set a long constant
- clss.property(_name, Z_LVAL(_constant.value), Php::Const);
-#endif
+ // set a long constant (cast is necessary because php uses longs, which
+ // have a different size on different platforms)
+ clss.property(_name, (int64_t)Z_LVAL(_constant.value), Php::Const);
break;
case IS_DOUBLE: