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

Switch continue #5775

merged 2 commits into from May 28, 2017


Copy link

peey commented May 25, 2017

Patch: Bug Fix? yes
Major: Breaking Change? no
Minor: New Feature? no
Deprecations? no
Spec Compliancy? yes
Tests Added/Pass? yes
Fixed Tickets Fixes #5725
License MIT
Doc PR no
Dependency Changes no

The only significant change is removing

-        if (state.inSwitchCase) return;

from block scoping transform. It was pretty ad-hoc, there wasn't any sense to it, and the correct functionality was already present in a later line

         // break statements mean something different in this context
         if (t.isBreakStatement(node) && t.isSwitchCase(parent)) return;

Rest of the changes are just tests

peey added 2 commits May 25, 2017
Ignore just non-label break statements in a switch, and allow continue
statments and lablled break statements.

Fixes #5725
Broken by fix to switch statements in block scoping

This comment has been minimized.

Copy link

mention-bot commented May 25, 2017

@peey, thanks for your PR! By analyzing the history of the files in this pull request, we identified @existentialism, @hzoo and @loganfsmyth to be potential reviewers.


This comment has been minimized.

Copy link

codecov bot commented May 27, 2017

Codecov Report

Merging #5775 into 7.0 will increase coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##              7.0    #5775      +/-   ##
+ Coverage   84.66%   84.71%   +0.04%     
  Files         282      282              
  Lines        9854     9853       -1     
  Branches     2766     2765       -1     
+ Hits         8343     8347       +4     
+ Misses        997      993       -4     
+ Partials      514      513       -1
Impacted Files Coverage Δ
...plugin-transform-es2015-block-scoping/src/index.js 92.13% <ø> (+1.22%) ⬆️
packages/babel-traverse/src/path/context.js 86.2% <0%> (+0.86%) ⬆️

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 cfe0a84...ee38938. Read the comment docs.

@jridgewell jridgewell merged commit 2579c5b into babel:7.0 May 28, 2017
3 checks passed
3 checks passed
ci/circleci Your tests passed on CircleCI!
codecov/project 84.71% (target 80%)
continuous-integration/travis-ci/pr The Travis CI build passed
@lock lock bot added the outdated label Oct 6, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
4 participants
You can’t perform that action at this time.