Skip to content

Conversation

JsonFreeman
Copy link
Contributor

ASI should kick in when we parse a type predicate, in a case like this:

interface I {
    foo(callback: (a: any, b: any) => void): I
    is(): boolean;
}

This should not be parsed as a type predicate. The grammar production should look something like

Type:
     Identifier [No line terminator here] is Type

@yuit
Copy link
Contributor

yuit commented Jun 9, 2015

lgtm

JsonFreeman added a commit that referenced this pull request Jun 9, 2015
Don't consume 'is' keyword if there is a preceding line terminator
@JsonFreeman JsonFreeman merged commit 6490d67 into master Jun 9, 2015
@JsonFreeman JsonFreeman deleted the typePredicateASI branch June 9, 2015 18:27
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants