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

Add constraint inference #197

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Add constraint inference #197

wants to merge 1 commit into from

Conversation

kaleidawave
Copy link
Owner

@kaleidawave kaleidawave commented Aug 26, 2024

Add parameter inference for passing as argument, getting a property from and calling

TODO more cases

  • Operator inference
  • Nested inference
  • Free variable thing
  • this inference
  • Test narrowing
  • Combing requests

Also not sure what to do here

function x(a, prop) {
    return a[prop]
}

x({ a: 1 }, "b")

@kaleidawave kaleidawave linked an issue Aug 26, 2024 that may be closed by this pull request
@kaleidawave kaleidawave added enhancement New feature or request inference Related to inferring the restriction of poly types labels Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request inference Related to inferring the restriction of poly types
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inferred generic (poly type) constraints
1 participant