Skip to content

Commit

Permalink
Require options param in parse function types
Browse files Browse the repository at this point in the history
Ensures ecmaVersion is required when calling one of these functions.
  • Loading branch information
antross authored and marijnh committed Sep 3, 2020
1 parent 646b614 commit e232621
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions acorn/dist/acorn.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ export as namespace acorn
export = acorn

declare namespace acorn {
function parse(input: string, options?: Options): Node
function parse(input: string, options: Options): Node

function parseExpressionAt(input: string, pos?: number, options?: Options): Node
function parseExpressionAt(input: string, pos: number, options: Options): Node

function tokenizer(input: string, options?: Options): {
function tokenizer(input: string, options: Options): {
getToken(): Token
[Symbol.iterator](): Iterator<Token>
}
Expand Down Expand Up @@ -37,9 +37,9 @@ declare namespace acorn {
class Parser {
constructor(options: Options, input: string, startPos?: number)
parse(this: Parser): Node
static parse(this: typeof Parser, input: string, options?: Options): Node
static parseExpressionAt(this: typeof Parser, input: string, pos: number, options?: Options): Node
static tokenizer(this: typeof Parser, input: string, options?: Options): {
static parse(this: typeof Parser, input: string, options: Options): Node
static parseExpressionAt(this: typeof Parser, input: string, pos: number, options: Options): Node
static tokenizer(this: typeof Parser, input: string, options: Options): {
getToken(): Token
[Symbol.iterator](): Iterator<Token>
}
Expand Down

0 comments on commit e232621

Please sign in to comment.