0
0
mirror of https://github.com/phpv8/v8js.git synced 2024-12-22 07:01:52 +00:00

make it compile with PHP 7.4 on Windows

This commit is contained in:
Jan-E 2020-04-05 06:24:58 +02:00
parent c03cb4b345
commit 672d6952fd
4 changed files with 5 additions and 3 deletions

View File

@ -31,7 +31,9 @@
#include <cmath>
extern "C" {
#ifndef _WIN32
#include "php_config.h"
#endif
/* work around incompatibilities regarding isnan() and isfinite() macros,
* affecting PHP versions before 7.4. */

View File

@ -85,7 +85,7 @@ static v8::Local<v8::Value> v8js_hash_to_jsarr(zval *value, v8::Isolate *isolate
if (i > 0)
{
zval *data;
ulong index = 0;
zend_ulong index = 0;
#if PHP_VERSION_ID >= 70300
if (myht && !(GC_FLAGS(myht) & GC_IMMUTABLE))

View File

@ -364,7 +364,7 @@ V8JS_METHOD(require)
}
zval *data;
ulong index = 0;
zend_ulong index = 0;
ZEND_HASH_FOREACH_VAL(ht, data) {
if (Z_TYPE_P(data) != IS_STRING) {

View File

@ -627,7 +627,7 @@ v8::Local<v8::Value> v8js_named_property_callback(v8::Local<v8::Name> property_n
v8js_ctx *ctx = (v8js_ctx *) isolate->GetData(0);
v8::String::Utf8Value cstr(isolate, property);
const char *name = ToCString(cstr);
uint name_len = cstr.length();
uint32_t name_len = cstr.length();
char *lower = estrndup(name, name_len);
zend_string *method_name;