Skip to content

Deoptimize awaited expressions#4162

Merged
lukastaegert merged 1 commit intomasterfrom
gh-4161-await-dropping-code
Jul 1, 2021
Merged

Deoptimize awaited expressions#4162
lukastaegert merged 1 commit intomasterfrom
gh-4161-await-dropping-code

Conversation

@lukastaegert
Copy link
Copy Markdown
Member

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

List any relevant issue numbers:
Resolves #4161

Description

Currently, we are not tracking object deoptimizations through await expressions. This PR simplifies the logic here by always deoptimizing await expressions to avoid the complicated promise logic

@lukastaegert lukastaegert force-pushed the gh-4161-await-dropping-code branch from 55b60aa to c9f63de Compare July 1, 2021 05:08
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jul 1, 2021

Thank you for your contribution! ❤️

You can try out this pull request locally by installing Rollup via

npm install rollup/rollup#gh-4161-await-dropping-code

or load it into the REPL:
https://rollupjs.org/repl/?pr=4162

@codecov
Copy link
Copy Markdown

codecov Bot commented Jul 1, 2021

Codecov Report

Merging #4162 (c9f63de) into master (5b55f99) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #4162   +/-   ##
=======================================
  Coverage   98.28%   98.28%           
=======================================
  Files         201      201           
  Lines        7127     7130    +3     
  Branches     2088     2089    +1     
=======================================
+ Hits         7005     7008    +3     
  Misses         58       58           
  Partials       64       64           
Impacted Files Coverage Δ
src/ast/ExecutionContext.ts 100.00% <ø> (ø)
src/ast/nodes/ArrowFunctionExpression.ts 100.00% <ø> (ø)
src/ast/nodes/shared/FunctionNode.ts 100.00% <ø> (ø)
src/ast/nodes/AwaitExpression.ts 100.00% <100.00%> (ø)
src/ast/nodes/ReturnStatement.ts 100.00% <100.00%> (ø)
src/ast/nodes/YieldExpression.ts 100.00% <100.00%> (ø)

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 5b55f99...c9f63de. Read the comment docs.

@lukastaegert lukastaegert merged commit b9d9e6f into master Jul 1, 2021
@lukastaegert lukastaegert deleted the gh-4161-await-dropping-code branch July 1, 2021 05:17
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.

code incorrectly dropped

1 participant