Skip to content

Commit

Permalink
src: remove unused function GetName() in node_perf
Browse files Browse the repository at this point in the history
PR-URL: nodejs/node#49244
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Deokjin Kim <deokjin81.kim@gmail.com>
  • Loading branch information
sercher committed Apr 25, 2024
1 parent 1eea878 commit a28f870
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions graal-nodejs/src/node_perf.cc
Original file line number Diff line number Diff line change
Expand Up @@ -215,18 +215,6 @@ static void RemoveGarbageCollectionTracking(
GarbageCollectionCleanupHook(env);
}

// Gets the name of a function
inline Local<Value> GetName(Local<Function> fn) {
Local<Value> val = fn->GetDebugName();
if (val.IsEmpty() || val->IsUndefined()) {
Local<Value> boundFunction = fn->GetBoundFunction();
if (!boundFunction.IsEmpty() && !boundFunction->IsUndefined()) {
val = GetName(boundFunction.As<Function>());
}
}
return val;
}

// Notify a custom PerformanceEntry to observers
void Notify(const FunctionCallbackInfo<Value>& args) {
Environment* env = Environment::GetCurrent(args);
Expand Down

0 comments on commit a28f870

Please sign in to comment.