diff options
author | Octavian Soldea <octavian.soldea@intel.com> | 2019-07-12 02:23:12 +0300 |
---|---|---|
committer | Gabriel Schulhof <gabriel.schulhof@intel.com> | 2019-07-17 22:11:36 +0300 |
commit | da69f56e7f317651949bc2305513a005ae837ed0 (patch) | |
tree | 4c67e6f912bd1024c1133716bc63b77b068f7492 /src/js_native_api_types.h | |
parent | 54fcb14467b59e82d6e24bf44803462226a5de4d (diff) |
n-api: correct bug in napi_get_last_error
napi_get_last_error returns incorrect napi_status.
PR-URL: https://github.com/nodejs/node/pull/28702
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Diffstat (limited to 'src/js_native_api_types.h')
-rw-r--r-- | src/js_native_api_types.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/js_native_api_types.h b/src/js_native_api_types.h index fc9718a699c..ae8fedb1463 100644 --- a/src/js_native_api_types.h +++ b/src/js_native_api_types.h @@ -81,6 +81,10 @@ typedef enum { napi_bigint_expected, napi_date_expected, } napi_status; +// Note: when adding a new enum value to `napi_status`, please also update +// `const int last_status` in `napi_get_last_error_info()' definition, +// in file js_native_api_v8.cc. Please also update the definition of +// `napi_status` in doc/api/n-api.md to reflect the newly added value(s). typedef napi_value (*napi_callback)(napi_env env, napi_callback_info info); |