Skip to content

Commit

Permalink
perf: use Object::with_prototype_and_properties for CallSite (denol…
Browse files Browse the repository at this point in the history
  • Loading branch information
lucacasonato authored Aug 6, 2024
1 parent 5766495 commit 0a28b7a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1020,8 +1020,8 @@ fn make_patched_callsite<'s>(
callsite: v8::Local<'s, v8::Object>,
prototype: v8::Local<'s, v8::Object>,
) -> v8::Local<'s, v8::Object> {
let out_obj = Object::new(scope);
out_obj.set_prototype(scope, prototype.into());
let out_obj =
Object::with_prototype_and_properties(scope, prototype.into(), &[], &[]);
let orig_key = original_call_site_key(scope);
out_obj.set_private(scope, orig_key, callsite.into());
out_obj
Expand Down

0 comments on commit 0a28b7a

Please sign in to comment.