Remove additional error from error example (#1097)
The example with `Concrete` and `Template` is supposed to highlight that adding properties to a protocol in the implementation of a method is not supported, and does not add to the required signature of the protocol. However, this also has the problem of `Concrete` not being a `Template` anyway because it is missing that `method`.
This commit is contained in:
parent
5a3ff934c5
commit
e0a2affe5d
|
@ -369,6 +369,9 @@ Examples::
|
|||
self.name = name
|
||||
self.value = value
|
||||
|
||||
def method(self) -> None:
|
||||
return
|
||||
|
||||
var: Template = Concrete('value', 42) # OK
|
||||
|
||||
To distinguish between protocol class variables and protocol instance
|
||||
|
|
Loading…
Reference in New Issue