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

Make functions of a single parameter #382

Closed
clarus opened this issue Oct 7, 2023 · 1 comment
Closed

Make functions of a single parameter #382

clarus opened this issue Oct 7, 2023 · 1 comment

Comments

@clarus
Copy link
Collaborator

clarus commented Oct 7, 2023

It seems that to compile code using inference of (static) methods, it is helpful to replace the Dot and DoubleColon classes with more explicit ones, where we explicit the type of parameters, the type of result, and the Self / base type. This might be helpful because there is also the parameterized monad M to infer, and in this way we make it explicit.

The goal of this issue is to implement such improvements with:

  • all functions taking exactly one parameter (no currying)
  • more explicit types for the Dot and DoubleColon classes
  • the State.Trait parameter for the monad M added in more places, including in the header of type definitions or classes. This is because it is supposed to always be available anyway and can always be useful in case there is an arrow type.

As a result, we should be able to translate all the existing examples that compile, plus:

  • cargo/concurrent_tests.v
  • the ones using debug_tuple_field2_finish
@clarus
Copy link
Collaborator Author

clarus commented Mar 20, 2024

Closed by #472

@clarus clarus closed this as completed Mar 20, 2024
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

No branches or pull requests

1 participant