Skip to content

[spec] AmbientExternalModuleDeclaration missing "declare"? #1176

@yortus

Description

@yortus

The grammar in Appendix A of the spec does not appear to allow the syntax:

declare module "foo" {
   //...
}

In particular, the grammar does not appear to allow the keyword declare to immediately precede the module keyword in the AmbientExternalModuleDeclaration production rule or any usage thereof. The compiler, however, does require the declare to be present. Am I missing something?

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptFixedA PR has been merged for this issueSpecIssues related to the TypeScript language specification

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions