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

Implement Generic Type Method Declaration #127

Open
Alexius-Huang opened this issue Jun 15, 2020 · 0 comments
Open

Implement Generic Type Method Declaration #127

Alexius-Huang opened this issue Jun 15, 2020 · 0 comments

Comments

@Alexius-Huang
Copy link
Owner

What?
Currently method declaration for generic type seems haven't implemented yet.

Why?
For instance, we cannot declare method for types like List<element>

How?
Generic type method of specific type:

def List<Num>.<method-name>(<params: type>): <output> do
  ...
end

Generic type method of generic type:

def List<element: T>.<method-name>(<params: type | T>): <output | T> do
  ...
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant