diff options
author | Joyee Cheung <joyeec9h3@gmail.com> | 2019-01-16 22:00:55 +0300 |
---|---|---|
committer | Joyee Cheung <joyeec9h3@gmail.com> | 2019-02-01 02:43:27 +0300 |
commit | ca9e24e8b43b89dc705227a4ed29172c2a95f57f (patch) | |
tree | daba09ee200dab1bff3fb7bc02124b88756b133d /src/node_errors.cc | |
parent | 99c3243b229d4e552eadf1abf296440e20c604f8 (diff) |
src: move public C++ APIs into src/api/*.cc
This patch moves most of the public C++ APIs into src/api/*.cc
so that it's easier to tell that we need to be careful about
the compatibility of these code.
Some APIs, like `node::LoadEnvironmet()`, `node::Start()` and
`node::Init()` still stay in `node.cc` because they are still
very specific to our use cases and do not work quite well yet
for embedders anyway - we could not even manage to write cctest for
them at the moment.
PR-URL: https://github.com/nodejs/node/pull/25541
Reviewed-By: Gus Caplan <me@gus.host>
Diffstat (limited to 'src/node_errors.cc')
-rw-r--r-- | src/node_errors.cc | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/src/node_errors.cc b/src/node_errors.cc index 23a65bd2251..5a9f08839ce 100644 --- a/src/node_errors.cc +++ b/src/node_errors.cc @@ -763,19 +763,6 @@ void FatalException(Isolate* isolate, } } -void FatalException(Isolate* isolate, const v8::TryCatch& try_catch) { - // If we try to print out a termination exception, we'd just get 'null', - // so just crashing here with that information seems like a better idea, - // and in particular it seems like we should handle terminations at the call - // site for this function rather than by printing them out somewhere. - CHECK(!try_catch.HasTerminated()); - - HandleScope scope(isolate); - if (!try_catch.IsVerbose()) { - FatalException(isolate, try_catch.Exception(), try_catch.Message()); - } -} - void FatalException(const FunctionCallbackInfo<Value>& args) { Isolate* isolate = args.GetIsolate(); Environment* env = Environment::GetCurrent(isolate); |