0
0
mirror of https://github.com/phpv8/v8js.git synced 2024-11-08 13:48:40 +00:00

Merge pull request #441 from Jan-E/php74win

make it compile with PHP 7.4 on Windows
This commit is contained in:
Stefan Siegl 2020-04-05 18:24:01 +02:00 committed by GitHub
commit a3eab09e96
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
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;