Skip to content

arguments should not be allowed class static block #48152

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

Closed
Zzzen opened this issue Mar 7, 2022 · 0 comments Β· Fixed by #48172
Closed

arguments should not be allowed class static block #48152

Zzzen opened this issue Mar 7, 2022 · 0 comments Β· Fixed by #48172
Labels
Bug A bug in TypeScript Effort: Moderate Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual". Help Wanted You can do this
Milestone

Comments

@Zzzen
Copy link
Contributor

Zzzen commented Mar 7, 2022

Bug Report

πŸ”Ž Search Terms

arguments class static block error

πŸ•— Version & Regression Information

  • This is the behavior in every version I tried

⏯ Playground Link

Playground link with relevant code

πŸ’» Code

function D3() {
  return class T {
    static {
      while(1) {
        arguments // should error
      }
    }
  }
}

πŸ™ Actual behavior

no error reported.

πŸ™‚ Expected behavior

a syntax error should be reported.

image

related to #44269

@DanielRosenwasser DanielRosenwasser added Bug A bug in TypeScript Effort: Moderate Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual". Help Wanted You can do this labels Mar 8, 2022
@sandersn sandersn added this to the Backlog milestone Mar 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in TypeScript Effort: Moderate Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual". Help Wanted You can do this
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants