Skip to content

arguments should not be allowed class static blockΒ #48152

@Zzzen

Description

@Zzzen

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptEffort: ModerateRequires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Help WantedYou can do this

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions