Skip to content

Can't use static as an object key #3129

@markandrus

Description

@markandrus

Hi,

My issue appears very similar to #829. I'd like to type the webidl2.js AST. Some of the AST nodes include a static property. When I try to type this with Flow, e.g.

declare interface IDLMember {
  static: boolean;
  // additional properties elided
};

I get the following error.

$ flow check
Library parse error:
decls/idlmember.js:2
  3:   static: boolean;
       ^^^^^^ Use of future reserved word in strict mode

Found 1 error

Moreover, disabling module.use_strict does not appear to have any affect.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions