Skip to content

[Bug]: using in switch is not compiled #16422

@nicolo-ribaudo

Description

@nicolo-ribaudo

💻

  • Would you like to work on a fix?

How are you using Babel?

Other (Next.js, Gatsby, vue-cli, ...)

Input code

{
  switch (1) {
    case 1:
      using a = 1;
    case 2:
      using b = 2;
  }
  using c = 4;
}

https://babeljs.io/repl#?browsers=&build=&builtIns=false&corejs=3.21&spec=false&loose=false&code_lz=N4KABGDODuCWAuBjAFmAFARgJRlBCiAhpAKZgYBc4-EArpLAHYDmYhYAvOQNzUHFkATFRp0GLMACNOYQbwgBfavSatEMgCy8FQA&debug=false&forceAllTransforms=false&modules=commonjs&shippedProposals=false&circleciRepo=&evaluate=true&fileSize=false&timeTravel=false&sourceType=script&lineWrap=true&presets=stage-3%2Ctypescript&prettier=false&targets=&version=7.24.4&externalPlugins=&assumptions=%7B%7D

Configuration file name

No response

Configuration

No response

Current and expected behavior

using is not transpiled, but it shuold

Environment

v7.24.4

Possible solution

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions