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

[Merged by Bors] - Refactor guards into a ContextCleanupGuard abstraction #2890

Closed
wants to merge 1 commit into from

Conversation

jedel1043
Copy link
Member

Noticed we were using this pattern on a couple of places, so I abstracted it behind a ContextCleanupGuard struct.

Let me know if you remember another place where this pattern would apply.

@jedel1043 jedel1043 added the Internal Category for changelog label May 1, 2023
@jedel1043 jedel1043 added this to the v0.17.0 milestone May 1, 2023
@github-actions
Copy link

github-actions bot commented May 1, 2023

Test262 conformance changes

Test result main count PR count difference
Total 94,601 94,601 0
Passed 73,226 73,226 0
Ignored 17,540 17,540 0
Failed 3,835 3,835 0
Panics 0 0 0
Conformance 77.41% 77.41% 0.00%

@codecov
Copy link

codecov bot commented May 1, 2023

Codecov Report

Merging #2890 (8568784) into main (dff815d) will increase coverage by 0.01%.
The diff coverage is 87.09%.

@@            Coverage Diff             @@
##             main    #2890      +/-   ##
==========================================
+ Coverage   51.23%   51.24%   +0.01%     
==========================================
  Files         427      427              
  Lines       42520    42528       +8     
==========================================
+ Hits        21786    21795       +9     
+ Misses      20734    20733       -1     
Impacted Files Coverage Δ
boa_engine/src/builtins/eval/mod.rs 64.42% <50.00%> (+0.53%) ⬆️
boa_engine/src/context/mod.rs 48.13% <90.90%> (+2.31%) ⬆️
boa_engine/src/vm/code_block.rs 55.63% <100.00%> (+0.07%) ⬆️

Copy link
Member

@HalidOdat HalidOdat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice refactor! Looks good to me! :)

Copy link
Member

@raskad raskad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes a lot of sense and makes eval code a lot safer to adjust.

@raskad
Copy link
Member

raskad commented May 2, 2023

bors r+

bors bot pushed a commit that referenced this pull request May 2, 2023
Noticed we were using this pattern on a couple of places, so I abstracted it behind a `ContextCleanupGuard` struct.

Let me know if you remember another place where this pattern would apply.
@bors
Copy link

bors bot commented May 2, 2023

Pull request successfully merged into main.

Build succeeded!

The publicly hosted instance of bors-ng is deprecated and will go away soon.

If you want to self-host your own instance, instructions are here.
For more help, visit the forum.

If you want to switch to GitHub's built-in merge queue, visit their help page.

@bors bors bot changed the title Refactor guards into a ContextCleanupGuard abstraction [Merged by Bors] - Refactor guards into a ContextCleanupGuard abstraction May 2, 2023
@bors bors bot closed this May 2, 2023
@bors bors bot deleted the cleanup-guard branch May 2, 2023 23:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Internal Category for changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants