Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cut an identifier at blank/space after dot. #400

Merged
merged 12 commits into from
Apr 28, 2022
Merged

Conversation

cristianoc
Copy link
Collaborator

@cristianoc cristianoc commented Apr 28, 2022

Since the parser allows space after ".", some autocomplete user intent can get lost.
For example:

type record = {
  someProp: SomeModule. // <-- cursor
  otherProp: string,
}

The parser will parse as SomeModule.otherProp then error on the ":" token.
The autocomplete engine now recognises these situations and splits up SomeModule.otherProp, which is provided by the parser's AST, into SomeModule..

@cristianoc cristianoc changed the title Cut an identified at blank/space after dot. Cut an identifier at blank/space after dot. Apr 28, 2022
@cristianoc cristianoc merged commit f7998d7 into master Apr 28, 2022
@cristianoc cristianoc deleted the spaceAfterDot branch April 28, 2022 12:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant