Skip to content

Commit

Permalink
Merge pull request #274 from zopefoundation/document_Provides_signature
Browse files Browse the repository at this point in the history
improve `declarations.Provides` documentation
  • Loading branch information
d-maurer authored Sep 7, 2023
2 parents bf4418e + 5f6d95a commit 31dba21
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/zope/interface/declarations.py
Original file line number Diff line number Diff line change
Expand Up @@ -789,7 +789,11 @@ def __get__(self, inst, cls):
InstanceDeclarations = weakref.WeakValueDictionary()

def Provides(*interfaces): # pylint:disable=function-redefined
"""Cache instance declarations
"""Declaration for an instance of *cls*.
The correct signature is ``cls, *interfaces``.
The *cls* is necessary to avoid the
construction of inconsistent resolution orders.
Instance declarations are shared among instances that have the same
declaration. The declarations are cached in a weak value dictionary.
Expand Down

0 comments on commit 31dba21

Please sign in to comment.