File tree Expand file tree Collapse file tree 5 files changed +9
-22
lines changed Expand file tree Collapse file tree 5 files changed +9
-22
lines changed Original file line number Diff line number Diff line change @@ -173,8 +173,8 @@ void LoadAsyncWrapperInfo(Environment* env) {
173173
174174
175175Local<Value> AsyncWrap::MakeCallback (const Local<Function> cb,
176- int argc,
177- Local<Value>* argv) {
176+ int argc,
177+ Local<Value>* argv) {
178178 CHECK (env ()->context () == env ()->isolate ()->GetCurrentContext ());
179179
180180 Local<Function> pre_fn = env ()->async_hooks_pre_function ();
@@ -254,7 +254,6 @@ Local<Value> AsyncWrap::MakeCallback(const Local<Function> cb,
254254 env ()->tick_callback_function ()->Call (process, 0 , nullptr );
255255
256256 if (try_catch.HasCaught ()) {
257- tick_info->set_last_threw (true );
258257 return Undefined (env ()->isolate ());
259258 }
260259
Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ inline uint32_t Environment::DomainFlag::count() const {
118118 return fields_[kCount ];
119119}
120120
121- inline Environment::TickInfo::TickInfo () : in_tick_(false ), last_threw_( false ) {
121+ inline Environment::TickInfo::TickInfo () : in_tick_(false ) {
122122 for (int i = 0 ; i < kFieldsCount ; ++i)
123123 fields_[i] = 0 ;
124124}
@@ -139,10 +139,6 @@ inline uint32_t Environment::TickInfo::index() const {
139139 return fields_[kIndex ];
140140}
141141
142- inline bool Environment::TickInfo::last_threw () const {
143- return last_threw_;
144- }
145-
146142inline uint32_t Environment::TickInfo::length () const {
147143 return fields_[kLength ];
148144}
@@ -155,10 +151,6 @@ inline void Environment::TickInfo::set_index(uint32_t value) {
155151 fields_[kIndex ] = value;
156152}
157153
158- inline void Environment::TickInfo::set_last_threw (bool value) {
159- last_threw_ = value;
160- }
161-
162154inline Environment::ArrayBufferAllocatorInfo::ArrayBufferAllocatorInfo () {
163155 for (int i = 0 ; i < kFieldsCount ; ++i)
164156 fields_[i] = 0 ;
Original file line number Diff line number Diff line change @@ -74,12 +74,11 @@ bool Environment::KickNextTick(Environment::AsyncCallbackScope* scope) {
7474 }
7575
7676 // process nextTicks after call
77- TryCatch try_catch;
77+ TryCatch try_catch ( isolate ()) ;
7878 try_catch.SetVerbose (true );
7979 tick_callback_function ()->Call (process_object (), 0 , nullptr );
8080
8181 if (try_catch.HasCaught ()) {
82- info->set_last_threw (true );
8382 return false ;
8483 }
8584
Original file line number Diff line number Diff line change @@ -332,12 +332,10 @@ class Environment {
332332 inline uint32_t * fields ();
333333 inline int fields_count () const ;
334334 inline bool in_tick () const ;
335- inline bool last_threw () const ;
336335 inline uint32_t index () const ;
337336 inline uint32_t length () const ;
338337 inline void set_in_tick (bool value);
339338 inline void set_index (uint32_t value);
340- inline void set_last_threw (bool value);
341339
342340 private:
343341 friend class Environment ; // So we can call the constructor.
@@ -351,7 +349,6 @@ class Environment {
351349
352350 uint32_t fields_[kFieldsCount ];
353351 bool in_tick_;
354- bool last_threw_;
355352
356353 DISALLOW_COPY_AND_ASSIGN (TickInfo);
357354 };
Original file line number Diff line number Diff line change @@ -1119,10 +1119,10 @@ void SetupPromises(const FunctionCallbackInfo<Value>& args) {
11191119
11201120
11211121Local<Value> MakeCallback (Environment* env,
1122- Local<Value> recv,
1123- const Local<Function> callback,
1124- int argc,
1125- Local<Value> argv[]) {
1122+ Local<Value> recv,
1123+ const Local<Function> callback,
1124+ int argc,
1125+ Local<Value> argv[]) {
11261126 // If you hit this assertion, you forgot to enter the v8::Context first.
11271127 CHECK_EQ (env->context (), env->isolate ()->GetCurrentContext ());
11281128
@@ -1154,7 +1154,7 @@ Local<Value> MakeCallback(Environment* env,
11541154 }
11551155 }
11561156
1157- TryCatch try_catch;
1157+ TryCatch try_catch (env-> isolate ()) ;
11581158 try_catch.SetVerbose (true );
11591159
11601160 if (has_domain) {
You can’t perform that action at this time.
0 commit comments