File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 19
19
#include < limits>
20
20
#include < memory>
21
21
#include < mutex>
22
+ #include < type_traits>
22
23
#include < vector>
23
24
24
25
#include < nan.h>
@@ -121,7 +122,7 @@ class ProtectedProfilerMap {
121
122
}
122
123
123
124
WallProfiler* RemoveProfilerForIsolate (const v8::Isolate* isolate) {
124
- return UpdateProfilers ([isolate, this ](auto map) {
125
+ return UpdateProfilers ([isolate](auto map) {
125
126
auto it = map->find (isolate);
126
127
if (it != map->end ()) {
127
128
auto profiler = it->second ;
@@ -192,7 +193,7 @@ class ProtectedProfilerMap {
192
193
using ProfilerMap = std::unordered_map<const Isolate*, WallProfiler*>;
193
194
194
195
template <typename F>
195
- typename std::result_of<F( ProfilerMap*)>::type UpdateProfilers (F updateFn) {
196
+ std::invoke_result_t <F, ProfilerMap*> UpdateProfilers (F updateFn) {
196
197
// use mutex to prevent two isolates of updating profilers concurrently
197
198
std::lock_guard<std::mutex> lock (update_mutex_);
198
199
You can’t perform that action at this time.
0 commit comments