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

Design Meeting Notes, 1/21/2022 #47726

Closed
DanielRosenwasser opened this issue Feb 3, 2022 · 0 comments
Closed

Design Meeting Notes, 1/21/2022 #47726

DanielRosenwasser opened this issue Feb 3, 2022 · 0 comments
Labels
Design Notes Notes from our design meetings

Comments

@DanielRosenwasser
Copy link
Member

Destructuring and Narrowing

#47337

  • If you narrow with "a" in value when value is generic, and then grab a with value.a, it works, but doesn't with destructuring.
    • Inconsistent!
  • Sometimes it makes sense to get the base constraint in destructured valies instead of the generic, and sometimes it's best to keep the original type.
    • But threading the code to do that is difficult.
  • Lots of bug reports where people say "oh no, I wanted the deferred version" or "I want the base constrained person"
  • Seems like there are a well-understood set of cases that can be iterated on in the PR.
@DanielRosenwasser DanielRosenwasser added the Design Notes Notes from our design meetings label Feb 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Design Notes Notes from our design meetings
Projects
None yet
Development

No branches or pull requests

1 participant