Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[exec - function] Add constructor property to function.prototype #534

Closed
wants to merge 3 commits into from

Conversation

croraf
Copy link
Contributor

@croraf croraf commented Jun 27, 2020

Intended to solve this #533 .
It is actually a couple of lines of change, but I based it on refactor PR which should be merged first: #529

I basically added proto.set_field("constructor", val.clone()); to function.prototype. val here is:

let new_func = Object::function(func);
let val = Value::from(new_func);

https://github.com/boa-dev/boa/pull/534/files#diff-d7bd296d9ca534161e198b8c141ca51fR140-L149

Someone has to doublecheck if setting the val.clone() here is correct.

@codecov
Copy link

codecov bot commented Jun 27, 2020

Codecov Report

Merging #534 into master will increase coverage by 0.00%.
The diff coverage is 42.85%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #534   +/-   ##
=======================================
  Coverage   68.33%   68.34%           
=======================================
  Files         172      172           
  Lines       10495    10496    +1     
=======================================
+ Hits         7172     7173    +1     
  Misses       3323     3323           
Impacted Files Coverage Δ
boa/src/exec/mod.rs 68.64% <42.85%> (+0.10%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 641dce1...34b1bc9. Read the comment docs.

@RageKnify
Copy link
Member

@croraf I think #642 fixed this #533, this PR can be closed, right?

@HalidOdat
Copy link
Member

@croraf I think #642 fixed this #533, this PR can be closed, right?

Yep #642 did add that, so closing this.

@HalidOdat HalidOdat closed this Oct 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants