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

Set-theoretic types: inference of patterns and guards #13227

Open
10 of 35 tasks
josevalim opened this issue Jan 5, 2024 · 0 comments
Open
10 of 35 tasks

Set-theoretic types: inference of patterns and guards #13227

josevalim opened this issue Jan 5, 2024 · 0 comments

Comments

@josevalim
Copy link
Member

josevalim commented Jan 5, 2024

The goal of this issue is to track the main tasks for the first milestone of set theoretic types: type inference of patterns and guards, followed by body checking.

Typing description:

  • Non-divisible types (integer, floats, pids, etc)
  • Dynamic
  • Atoms
  • Maps
  • Tuples
  • Lists
  • Functions

Type inference and checking:

  • Tracking of variables
  • Type inference and checking of bitstring syntax
  • Type inference of patterns
  • Type inference of guards
  • Support of every syntax construct
    • structs
    • rescue
    • map updates
    • __CALLER__
    • ...
  • Support for __info__
  • Support for local calls
  • Support for application of Kernel and stdlib functions
  • Support for application of Map operations

These are additional features not required for the first milestone:

  • Storing of inferred types in .beam files
  • Detecting overlapping clauses (cond, case, receive, try)
  • Detecting unused clauses (cond, case, receive, try)
  • Exhaustiveness checks
  • Typing of protocol implementations
  • Tracking of mismatches in equality operators
  • Tracking of structs in ordered comparison operators
  • Support for macros
  • Type checking during evaluation

Long term:

  • Occurrence typing
  • Type variables
  • Strong arrows
  • Row polymorphism
  • Behaviours
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

1 participant