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

Fix repl autocomplete for Records and Unions #937

Merged
merged 1 commit into from
May 4, 2019

Conversation

basile-henry
Copy link
Collaborator

Remove autocomplete for Record types and Union literals as the field accessor/Union construction is not valid in these cases:

⊢ :let x = { foo : Natural, bar : Text }

x : Type

⊢ x.
x.bar  x.foo
⊢ x.bar

y : { bar : Text, foo : Natural }
it : Text

Error: Not a record or a union

x.bar
(stdin):1:1
⊢ :let y = < Foo = 3 | Bar >

y : < Foo : Natural | Bar >

⊢ y.Bar

y : { bar : Text, foo : Natural }
y : < Bar | Foo : Natural >
it : Text

Error: Not a record or a union

y.Bar
(stdin):1:1

@basile-henry basile-henry self-assigned this May 4, 2019
@Gabriella439 Gabriella439 merged commit 29ccd7d into master May 4, 2019
@Gabriella439 Gabriella439 deleted the fix-repl-completion branch May 4, 2019 19:13
@Gabriella439
Copy link
Collaborator

Thank you 🙂

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.

None yet

2 participants