/src/node/src/node_external_reference.cc
Line | Count | Source (jump to first uncovered line) |
1 | | #include "node_external_reference.h" |
2 | | #include <cinttypes> |
3 | | #include <vector> |
4 | | #include "base_object-inl.h" |
5 | | #include "util.h" |
6 | | |
7 | | namespace node { |
8 | | |
9 | 0 | const std::vector<intptr_t>& ExternalReferenceRegistry::external_references() { |
10 | 0 | if (!is_finalized_) { |
11 | 0 | external_references_.push_back(reinterpret_cast<intptr_t>(nullptr)); |
12 | 0 | is_finalized_ = true; |
13 | 0 | } |
14 | |
|
15 | 0 | return external_references_; |
16 | 0 | } |
17 | | |
18 | 0 | ExternalReferenceRegistry::ExternalReferenceRegistry() { |
19 | 0 | this->Register(BaseObject::LazilyInitializedJSTemplateConstructor); |
20 | |
|
21 | 0 | #define V(modname) _register_external_reference_##modname(this); |
22 | 0 | EXTERNAL_REFERENCE_BINDING_LIST(V) |
23 | 0 | #undef V |
24 | | // TODO(joyeecheung): collect more external references here. |
25 | 0 | } |
26 | | |
27 | | } // namespace node |