src: move version metadata into node_metadata{.h, .cc}#24774
Closed
joyeecheung wants to merge 3 commits intonodejs:masterfrom
Closed
src: move version metadata into node_metadata{.h, .cc}#24774joyeecheung wants to merge 3 commits intonodejs:masterfrom
joyeecheung wants to merge 3 commits intonodejs:masterfrom
Conversation
Move these macros to util.h so they can be shared among different C++ files. Also, renames `READONLY_BOOLEAN_PROPERTY` to `READONLY_TRUE_PROPERTY` (since it sets the property to true), and use `ToV8Value` in `READONLY_STRING_PROPERTY`.
This patch moves the computation of version metadata from node.cc
into node_metadata{.h, .cc}, and creates a macro that can be
used to iterate over the available version keys (v8, uv, .etc).
This makes the code clearer as now we no longer need to add
all the headers in node.cc just to compute the versions, and
makes it easier to reuse the version definitions.
Member
Author
jasnell
approved these changes
Dec 1, 2018
joyeecheung
commented
Dec 1, 2018
node.gyp
Outdated
| 'src/node_url.cc', | ||
| 'src/node_util.cc', | ||
| 'src/node_v8.cc', | ||
| 'src/node_metadata.cc', |
Member
Author
There was a problem hiding this comment.
Oops, should've sort these
cjihrig
approved these changes
Dec 1, 2018
Member
Author
|
@mmarchini BTW, it should be possible to make these directly available as post-mortem metadata that can be consumed by llnode, same goes for the other recent additions like node_binding.cc and node_native_module.cc, maybe we should design some common interface/macros to do this.. |
Member
Author
Member
Author
Member
|
Landed in ff7d053...d17d7bd |
Trott
pushed a commit
to Trott/io.js
that referenced
this pull request
Dec 4, 2018
Move these macros to util.h so they can be shared among different C++ files. Also, renames `READONLY_BOOLEAN_PROPERTY` to `READONLY_TRUE_PROPERTY` (since it sets the property to true), and use `ToV8Value` in `READONLY_STRING_PROPERTY`. PR-URL: nodejs#24774 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Trott
pushed a commit
to Trott/io.js
that referenced
this pull request
Dec 4, 2018
This patch moves the computation of version metadata from node.cc
into node_metadata{.h, .cc}, and creates a macro that can be
used to iterate over the available version keys (v8, uv, .etc).
This makes the code clearer as now we no longer need to add
all the headers in node.cc just to compute the versions, and
makes it easier to reuse the version definitions.
PR-URL: nodejs#24774
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
BridgeAR
pushed a commit
that referenced
this pull request
Dec 5, 2018
Move these macros to util.h so they can be shared among different C++ files. Also, renames `READONLY_BOOLEAN_PROPERTY` to `READONLY_TRUE_PROPERTY` (since it sets the property to true), and use `ToV8Value` in `READONLY_STRING_PROPERTY`. PR-URL: #24774 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
BridgeAR
pushed a commit
that referenced
this pull request
Dec 5, 2018
This patch moves the computation of version metadata from node.cc
into node_metadata{.h, .cc}, and creates a macro that can be
used to iterate over the available version keys (v8, uv, .etc).
This makes the code clearer as now we no longer need to add
all the headers in node.cc just to compute the versions, and
makes it easier to reuse the version definitions.
PR-URL: #24774
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
This was referenced Dec 7, 2018
refack
pushed a commit
to refack/node
that referenced
this pull request
Jan 14, 2019
Move these macros to util.h so they can be shared among different C++ files. Also, renames `READONLY_BOOLEAN_PROPERTY` to `READONLY_TRUE_PROPERTY` (since it sets the property to true), and use `ToV8Value` in `READONLY_STRING_PROPERTY`. PR-URL: nodejs#24774 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
refack
pushed a commit
to refack/node
that referenced
this pull request
Jan 14, 2019
This patch moves the computation of version metadata from node.cc
into node_metadata{.h, .cc}, and creates a macro that can be
used to iterate over the available version keys (v8, uv, .etc).
This makes the code clearer as now we no longer need to add
all the headers in node.cc just to compute the versions, and
makes it easier to reuse the version definitions.
PR-URL: nodejs#24774
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
src: move READONLY_* macros into util.h
Move these macros to util.h so they can be shared among different
C++ files.
Also, renames
READONLY_BOOLEAN_PROPERTYtoREADONLY_TRUE_PROPERTY(since it sets the property to true), and use
ToV8ValueinREADONLY_STRING_PROPERTY.src: move version metadata into node_metadata{.h, .cc}
This patch moves the computation of version metadata from node.cc
into node_metadata{.h, .cc}, and creates a macro that can be
used to iterate over the available version keys (v8, uv, .etc).
This makes the code clearer as now we no longer need to add
all the headers in node.cc just to compute the versions, and
makes it easier to reuse the version definitions.
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes