File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1291,11 +1291,11 @@ \subsection{Ownership Rules
12911291Most functions that return a reference to an object pass on ownership
12921292with the reference. In particular, all functions whose function it is
12931293to create a new object, such as \cfunction {PyInt_FromLong()} and
1294- \cfunction {Py_BuildValue()}, pass ownership to the receiver. Even if in
1295- fact, in some cases , you don't receive a reference to a brand new
1296- object, you still receive ownership of the reference . For instance,
1297- \cfunction {PyInt_FromLong()} maintains a cache of popular values and can
1298- return a reference to a cached item.
1294+ \cfunction {Py_BuildValue()}, pass ownership to the receiver. Even if
1295+ the object is not actually new , you still receive ownership of a new
1296+ reference to that object . For instance, \cfunction {PyInt_FromLong()}
1297+ maintains a cache of popular values and can return a reference to a
1298+ cached item.
12991299
13001300Many functions that extract objects from other objects also transfer
13011301ownership with the reference, for instance
You can’t perform that action at this time.
0 commit comments