diff --git a/binding.gyp b/binding.gyp index ebf184a5d..4323505dd 100644 --- a/binding.gyp +++ b/binding.gyp @@ -93,15 +93,8 @@ "-Wno-unused-parameter", "-Wno-unknown-warning-option", "-Wno-unused-const-variable", - "-Wno-undefined-internal", - "-Wno-deprecated-declarations" + "-Wno-undefined-internal" ], - "xcode_settings": { - "OTHER_CFLAGS": [ - "-Wno-deprecated-declarations" - ] - }, - "msvs_disabled_warnings": [4996], "include_dirs": [ "/usr/local/include", "IsUndefined()) { \ CHECK_TYPE_BOOLEAN(value, COMPRESSED_TYPE_INVALID); \ - compressed = value->BooleanValue() ? v_true : v_false; \ + compressed = Nan::To(value).FromJust() ? v_true : v_false; \ } \ } @@ -132,7 +132,8 @@ } #define CHECK_NUMBER_IN_INTERVAL(number, x, y, message) { \ - if (number->IntegerValue() <= x || number->IntegerValue() >= y) { \ + if (Nan::To(number).FromJust() <= x || \ + Nan::To(number).FromJust() >= y) { \ return Nan::ThrowRangeError(message); \ } \ } @@ -677,7 +678,7 @@ NAN_METHOD(BSecp256k1::recover) { v8::Local recid_object = info[2].As(); CHECK_TYPE_NUMBER(recid_object, RECOVERY_ID_TYPE_INVALID); CHECK_NUMBER_IN_INTERVAL(recid_object, -1, 4, RECOVERY_ID_VALUE_INVALID); - int recid = (int) recid_object->IntegerValue(); + int recid = (int) Nan::To(recid_object).FromJust(); unsigned int flags = SECP256K1_EC_COMPRESSED; UPDATE_COMPRESSED_VALUE(flags, info[3], SECP256K1_EC_COMPRESSED, SECP256K1_EC_UNCOMPRESSED);