File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -621,9 +621,14 @@ Object Protocol
621621   conservative, and may return ``0 `` in some cases even if *obj * is a unique 
622622   temporary object. 
623623
624-    If an object is a unique temporary, it is guaranteed that the reference 
625-    count is ``1 `` and it may be safe to modify the object in-place because 
626-    it is not visible to any other code. 
624+    If an object is a unique temporary, it is guaranteed that the current code 
625+    has the only reference to the object. For arguments to C functions, this 
626+    should be used instead of checking if the reference count is ``1 ``. Starting 
627+    with Python 3.14, the interpreter internally avoids some reference count 
628+    modifications when loading objects onto the operands stack by 
629+    :term: `borrowing <borrowed reference> ` references when possible, which means 
630+    that a reference count of ``1 `` by itself does not guarantee that a function 
631+    argument uniquely referenced. 
627632
628633   In the example below, ``my_func `` is called with a unique temporary object 
629634   as its argument:: 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments