-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Rename napi #37108
[WIP] Rename napi #37108
Conversation
Hmmm ... it's not running the github actions. |
|
43c8535
to
82f7a42
Compare
82f7a42
to
f4a5a6e
Compare
Note for any reviewers: it can be worth using a more accepting For example: |
@jayaddison if only github would have the option. The only option they have so far is side-by-side diff and -w. |
@jayaddison good idea though. Do all the renames in the first commit, and then make changes afterwards. |
Copied from the PR I closed:
|
@@ -20,6 +20,13 @@ typedef struct napi_handle_scope__* napi_handle_scope; | |||
typedef struct napi_escapable_handle_scope__* napi_escapable_handle_scope; | |||
typedef struct napi_callback_info__* napi_callback_info; | |||
typedef struct napi_deferred__* napi_deferred; | |||
#define node_api_env napi_env |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think all of these defines need to be guarded by NODE-API version 8. Otherwise add-ons could fail to compile against versions of Node.js that support the NODE-API version they are targeting but don't have the new defines. I see adding these defines as the equivalent to adding new supported functions to NODE-API.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mhdawson one concern is that NAPI_VERSION
itself has to change so, going forward, people would be able to select API versions by defining NODE_API_VERSION themselves.
@@ -100,12 +100,12 @@ | |||
/lib/internal/bootstrap/loaders.js @nodejs/modules | |||
/src/module_wrap* @nodejs/modules @nodejs/vm | |||
|
|||
# N-API | |||
# Node.js API |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Node.js API" seems like it will inevitably cause confusion. Is this the name that reached consensus in discussion? (I can't find the issue in the tracker. Maybe I'm looking in the wrong repository?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Trott I believe the name is still open for discussion at nodejs/abi-stable-node#420.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
node-api was what was being discussion to replace n-api and napi.
This PR is too big. I'll break it into several, starting with #37217. |
No description provided.