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

Include fields when completing for identifiers in a braced expr that is likely a module path #882

Merged
merged 2 commits into from
Jan 7, 2024

Conversation

zth
Copy link
Collaborator

@zth zth commented Jan 6, 2024

This is a QoL improvement intended to simplify the following scenario where you'd constructing a record without a type definition, but the expression is ambiguous and we don't know whether you're constructing a record yet or just typing some other expression:

let someRecord = {
  SomeModuleWithTheRecordDefinition.<com>
}

Previously you'd only get values from SomeModuleWithTheRecordDefinition, but with this change you'll also get any fields visible in that module.

@zth zth requested a review from cristianoc January 6, 2024 16:32
Copy link
Collaborator

@cristianoc cristianoc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there an analogue in pattern matching?

@zth
Copy link
Collaborator Author

zth commented Jan 7, 2024

Is there an analogue in pattern matching?

I don't think so, I think pattern matching already does the right thing.

@zth zth force-pushed the complete-fields-or-values-when-in-braced-expr branch from e02fe54 to 24fc824 Compare January 7, 2024 13:17
@zth zth merged commit cdd3983 into master Jan 7, 2024
4 checks passed
@zth zth deleted the complete-fields-or-values-when-in-braced-expr branch January 7, 2024 13:17
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.

2 participants