Closed
Description
For example:
@typeclass
def some(instance): ...
@some.instance(int):
def _some_int1(instance: int): ...
@some.instance(int):
def _some_int2(instance: int): ...
There are several things we can do:
- Allow this, in this case we need to provide a test case and docs about when this can be useful
- Add options, like
@typeclass(final=True)
, it won't allow exact duplicates when activated, but by default we will allow it - Always forbid, but in this case people might end up with a situation when they need to override an existing behaviour but can't