Added note about type parameters in ifaces.
Specficially, the type parameters should be left off of the function signatures in both the iface and the impl if they are already in the iface declaration.
This commit is contained in:
parent
e430a699f2
commit
c5b23c3400
@ -2504,6 +2504,10 @@ needed because it could also, for example, specify an implementation
|
||||
of `seq<int>`—the `of` clause *refers* to a type, rather than defining
|
||||
one.
|
||||
|
||||
Note that functions do not explicitly have the type parameters that
|
||||
are provided by the iface. It will cause a compile-time error if you
|
||||
include them in the iface or impl.
|
||||
|
||||
## Casting to an interface type
|
||||
|
||||
The above allows us to define functions that polymorphically act on
|
||||
|
Loading…
Reference in New Issue
Block a user