
    <e:)                         d dl Z  G d de j                  Z G d de j                  Z G d de j                  Zedk    rd dl Z  e j                     dS dS )	    Nc                   b    e Zd Zd Zd Zd Zd Zd Zd Zd Z	d Z
d	 Zd
 Zd Zd Zd Zd ZdS )TestLoadAttrCachec                      G d d           G fdd          }d } |            }t          d          D ]} ||          dk    sJ d _        d	 _        |                      ||          d
           d S )Nc                       e Zd ZdS )NTestLoadAttrCache.test_descriptor_added_after_optimization.<locals>.DescriptorN__name__
__module____qualname__     (/usr/lib/python3.11/test/test_opcache.py
Descriptorr              Dr   r   c                   *    e Zd Zd Z              ZdS )ETestLoadAttrCache.test_descriptor_added_after_optimization.<locals>.Cc                     d| _         d S )N   xselfs    r   __init__zNTestLoadAttrCache.test_descriptor_added_after_optimization.<locals>.C.__init__
   s    r   N)r	   r
   r   r   r   r   s   r   Cr   	   s)          
AAAr   r   c                     | j         S Nr   os    r   fzETestLoadAttrCache.test_descriptor_added_after_optimization.<locals>.f   s	    3Jr     r   c                     dS )N   r   r   instancevalues      r   <lambda>zLTestLoadAttrCache.test_descriptor_added_after_optimization.<locals>.<lambda>   s    1 r   c                      d S r   r   )argss    r   r'   zLTestLoadAttrCache.test_descriptor_added_after_optimization.<locals>.<lambda>   s    4 r   r#   )range__get____set__assertEqual)r   r   r    r   ir   s        @r   (test_descriptor_added_after_optimizationz:TestLoadAttrCache.test_descriptor_added_after_optimization   s    	 	 	 	 	 	 	 		 	 	 	 	 	 	 	 	 	
	 	 	 ACCt 	 	A1Q44199999<<
//
1q!!!!!r   c                 Z    G d d           G fddt                     } G d d|          d }d	 }fd
}t          d          D ]}|                      |                        |_        |_        t          d          D ]}|                      |                        d S )Nc                       e Zd ZdS )XTestLoadAttrCache.test_metaclass_descriptor_added_after_optimization.<locals>.DescriptorNr   r   r   r   r   r2      r   r   r   c                   $    e Zd Z              ZdS )WTestLoadAttrCache.test_metaclass_descriptor_added_after_optimization.<locals>.MetaclassNr	   r
   r   	attributer   s   r   	Metaclassr4              "
IIIr   r7   c                       e Zd ZdZdS )STestLoadAttrCache.test_metaclass_descriptor_added_after_optimization.<locals>.ClassTNr5   r   r   r   Classr:   !           IIIr   r;   	metaclassc                     dS NFr   r   r%   owners      r   r+   zUTestLoadAttrCache.test_metaclass_descriptor_added_after_optimization.<locals>.__get__$   s    5r   c                     d S r   r   r$   s      r   r,   zUTestLoadAttrCache.test_metaclass_descriptor_added_after_optimization.<locals>.__set__'       4r   c                       j         S r   r6   r;   s   r   r    zOTestLoadAttrCache.test_metaclass_descriptor_added_after_optimization.<locals>.f*       ?"r   r!   typer*   
assertTruer+   r,   assertFalser   r7   r+   r,   r    _r;   r   s         @@r   2test_metaclass_descriptor_added_after_optimizationzDTestLoadAttrCache.test_metaclass_descriptor_added_after_optimization   sD   	 	 	 	 	 	 	 		% 	% 	% 	% 	% 	% 	% 	% 	% 	%	 	 	 	 	i 	 	 	 		 	 		 	 		# 	# 	# 	# 	# t 	! 	!AOOAACC    $
$
t 	" 	"AQQSS!!!!	" 	"r   c                      G d dt                     } G d d|          fd}t          d          D ]}|                      |                        d S )Nc                   $    e Zd Zed             ZdS )VTestLoadAttrCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Metaclassc                     dS NTr   r   s    r   r6   z`TestLoadAttrCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Metaclass.attribute8       tr   Nr	   r
   r   propertyr6   r   r   r   r7   rR   7   -          X  r   r7   c                       e Zd ZdZdS )RTestLoadAttrCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.ClassFNr5   r   r   r   r;   rZ   <           IIIr   r;   r=   c                       j         S r   rF   rG   s   r   r    zNTestLoadAttrCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.f?   rH   r   r!   rJ   r*   rK   r   r7   r    rN   r;   s       @r   1test_metaclass_descriptor_shadows_class_attributezCTestLoadAttrCache.test_metaclass_descriptor_shadows_class_attribute6   s    	 	 	 	 	 	 	 	
	 	 	 	 	i 	 	 	 		# 	# 	# 	# 	# t 	! 	!AOOAACC    	! 	!r   c                 @    G d dt                     } G d d|          t          d             }fd}t          d          D ]}|                      |                        ||_        t          d          D ]}|                      |                        d S )	Nc                       e Zd ZdS )UTestLoadAttrCache.test_metaclass_set_descriptor_after_optimization.<locals>.MetaclassNr   r   r   r   r7   rb   F   r   r   r7   c                       e Zd ZdZdS )QTestLoadAttrCache.test_metaclass_set_descriptor_after_optimization.<locals>.ClassTNr5   r   r   r   r;   rd   I   r<   r   r;   r=   c                     dS r@   r   r   s    r   r6   zUTestLoadAttrCache.test_metaclass_set_descriptor_after_optimization.<locals>.attributeL   s    5r   c                       j         S r   rF   rG   s   r   r    zMTestLoadAttrCache.test_metaclass_set_descriptor_after_optimization.<locals>.fP   rH   r   r!   rJ   rW   r*   rK   r6   rL   r   r7   r6   r    rN   r;   s        @r   0test_metaclass_set_descriptor_after_optimizationzBTestLoadAttrCache.test_metaclass_set_descriptor_after_optimizationE   s   	 	 	 	 	 	 	 		 	 	 	 	i 	 	 	 	 
	 	 
		# 	# 	# 	# 	# t 	! 	!AOOAACC    '	t 	" 	"AQQSS!!!!	" 	"r   c                     G d dt                     } G d d|          fd}t          d          D ]}|                      |                        |`t          d          D ]}|                      |                        d S )Nc                   $    e Zd Zed             ZdS )UTestLoadAttrCache.test_metaclass_del_descriptor_after_optimization.<locals>.Metaclassc                     dS rT   r   r   s    r   r6   z_TestLoadAttrCache.test_metaclass_del_descriptor_after_optimization.<locals>.Metaclass.attribute]   rU   r   NrV   r   r   r   r7   rl   \   rX   r   r7   c                       e Zd ZdZdS )QTestLoadAttrCache.test_metaclass_del_descriptor_after_optimization.<locals>.ClassFNr5   r   r   r   r;   ro   a   r[   r   r;   r=   c                       j         S r   rF   rG   s   r   r    zMTestLoadAttrCache.test_metaclass_del_descriptor_after_optimization.<locals>.fd   rH   r   r!   rJ   r*   rK   r6   rL   r^   s       @r   0test_metaclass_del_descriptor_after_optimizationzBTestLoadAttrCache.test_metaclass_del_descriptor_after_optimization[   s    	 	 	 	 	 	 	 	
	 	 	 	 	i 	 	 	 		# 	# 	# 	# 	# t 	! 	!AOOAACC    t 	" 	"AQQSS!!!!	" 	"r   c                      G d d          fd}t          d          D ]}|                      |                        d S )Nc                       e Zd ZdZdS )NTestLoadAttrCache.test_type_descriptor_shadows_attribute_method.<locals>.ClassNr	   r
   r   mror   r   r   r;   ru   p   s        CCCr   r;   c                       j         S r   rw   rG   s   r   r    zJTestLoadAttrCache.test_type_descriptor_shadows_attribute_method.<locals>.fs   s    9r   r!   )r*   assertIsNoner   r    rN   r;   s      @r   -test_type_descriptor_shadows_attribute_methodz?TestLoadAttrCache.test_type_descriptor_shadows_attribute_methodo   s    	 	 	 	 	 	 	 		 	 	 	 	 t 	# 	#Aaacc""""	# 	#r   c                      G d d          fd}t          d          D ]%}|                      |            t                     &d S )Nc                       e Zd ZdZdS )NTestLoadAttrCache.test_type_descriptor_shadows_attribute_member.<locals>.ClassNr	   r
   r   __base__r   r   r   r;   r   z   s        HHHr   r;   c                       j         S r   r   rG   s   r   r    zJTestLoadAttrCache.test_type_descriptor_shadows_attribute_member.<locals>.f}       >!r   r!   )r*   assertIsobjectr{   s      @r   -test_type_descriptor_shadows_attribute_memberz?TestLoadAttrCache.test_type_descriptor_shadows_attribute_membery   s    	 	 	 	 	 	 	 		" 	" 	" 	" 	" t 	' 	'AMM!!##v&&&&	' 	'r   c                      G d d          fd}t          d          D ] }|                      |            d           !d S )Nc                       e Zd ZdZ dS )NTestLoadAttrCache.test_type_descriptor_shadows_attribute_getset.<locals>.ClassSpamNr   r   r   r   r;   r      s        HHHr   r;   c                       j         S r   )r	   rG   s   r   r    zJTestLoadAttrCache.test_type_descriptor_shadows_attribute_getset.<locals>.f   r   r   r!   r*   r-   r{   s      @r   -test_type_descriptor_shadows_attribute_getsetz?TestLoadAttrCache.test_type_descriptor_shadows_attribute_getset   s    	 	 	 	 	 	 	 		" 	" 	" 	" 	" t 	+ 	+AQQSS'****	+ 	+r   c                      G d dt                     } G d d|          fd}t          d          D ]}|                      |                        d S )Nc                       e Zd Zd ZdS )@TestLoadAttrCache.test_metaclass_getattribute.<locals>.Metaclassc                     dS rT   r   r   names     r   __getattribute__zQTestLoadAttrCache.test_metaclass_getattribute.<locals>.Metaclass.__getattribute__       tr   Nr	   r
   r   r   r   r   r   r7   r      #            r   r7   c                       e Zd ZdZdS )<TestLoadAttrCache.test_metaclass_getattribute.<locals>.ClassFNr5   r   r   r   r;   r      r[   r   r;   r=   c                       j         S r   rF   rG   s   r   r    z8TestLoadAttrCache.test_metaclass_getattribute.<locals>.f   rH   r   r!   r]   r^   s       @r   test_metaclass_getattributez-TestLoadAttrCache.test_metaclass_getattribute   s    	 	 	 	 	 	 	 		 	 	 	 	i 	 	 	 		# 	# 	# 	# 	# t 	! 	!AOOAACC    	! 	!r   c                 F    G d dt                     } G d dt                     } G d d|          fd}t          d	          D ]}|                      |                        |_        t          d	          D ]}|                      |                        d S )
Nc                   $    e Zd Zed             ZdS );TestLoadAttrCache.test_metaclass_swap.<locals>.OldMetaclassc                     dS rT   r   r   s    r   r6   zETestLoadAttrCache.test_metaclass_swap.<locals>.OldMetaclass.attribute   rU   r   NrV   r   r   r   OldMetaclassr      rX   r   r   c                   $    e Zd Zed             ZdS );TestLoadAttrCache.test_metaclass_swap.<locals>.NewMetaclassc                     dS r@   r   r   s    r   r6   zETestLoadAttrCache.test_metaclass_swap.<locals>.NewMetaclass.attribute   s    ur   NrV   r   r   r   NewMetaclassr      s-          X  r   r   c                       e Zd ZdS )4TestLoadAttrCache.test_metaclass_swap.<locals>.ClassNr   r   r   r   r;   r      r   r   r;   r=   c                       j         S r   rF   rG   s   r   r    z0TestLoadAttrCache.test_metaclass_swap.<locals>.f   rH   r   r!   rJ   r*   rK   	__class__rL   r   r   r   r    rN   r;   s        @r   test_metaclass_swapz%TestLoadAttrCache.test_metaclass_swap   s   	 	 	 	 	4 	 	 	
	 	 	 	 	4 	 	 	
	 	 	 	 	l 	 	 	 		# 	# 	# 	# 	# t 	! 	!AOOAACC    &t 	" 	"AQQSS!!!!	" 	"r   c                     G d d           G fdd          }d } |            }d|_         t          d          D ]?}|                     t                    5   ||           d d d            n# 1 swxY w Y   @d S )Nc                       e Zd ZdZdS )QTestLoadAttrCache.test_load_shadowing_slot_should_raise_type_error.<locals>.ClassslotNr	   r
   r   	__slots__r   r   r   r;   r              !IIIr   r;   c                   "    e Zd ZdZ j        ZdS )RTestLoadAttrCache.test_load_shadowing_slot_should_raise_type_error.<locals>.SneakyshadowedNr	   r
   r   r   r   	shadowingrG   s   r   Sneakyr              %I
IIIr   r   c                     | j          d S r   r   r   s    r   r    zMTestLoadAttrCache.test_load_shadowing_slot_should_raise_type_error.<locals>.f   s    KKKKr   *   r!   )r   r*   assertRaises	TypeErrorr   r   r    r   rN   r;   s        @r   0test_load_shadowing_slot_should_raise_type_errorzBTestLoadAttrCache.test_load_shadowing_slot_should_raise_type_error   s   	" 	" 	" 	" 	" 	" 	" 	"	# 	# 	# 	# 	# 	# 	# 	# 	# 	#	 	 	 FHH
t 	 	A""9--  !              	 	s   A55A9	<A9	c                      G d d           G fdd          }d } |            }t          d          D ]?}|                     t                    5   ||           d d d            n# 1 swxY w Y   @d S )Nc                       e Zd ZdZdS )RTestLoadAttrCache.test_store_shadowing_slot_should_raise_type_error.<locals>.Classr   Nr   r   r   r   r;   r      r   r   r;   c                   "    e Zd ZdZ j        ZdS )STestLoadAttrCache.test_store_shadowing_slot_should_raise_type_error.<locals>.Sneakyr   Nr   rG   s   r   r   r      r   r   r   c                     d| _         d S Nr   r   r   s    r   r    zNTestLoadAttrCache.test_store_shadowing_slot_should_raise_type_error.<locals>.f   s    AKKKr   r!   r*   r   r   r   s        @r   1test_store_shadowing_slot_should_raise_type_errorzCTestLoadAttrCache.test_store_shadowing_slot_should_raise_type_error   s   	" 	" 	" 	" 	" 	" 	" 	"	# 	# 	# 	# 	# 	# 	# 	# 	# 	#	 	 	 FHHt 	 	A""9--  !              	 	   A..A2	5A2	c                      G d d           G fdd          }d } |            }t          d          D ]?}|                     t                    5   ||           d d d            n# 1 swxY w Y   @d S )Nc                       e Zd ZdZdS )ITestLoadAttrCache.test_load_borrowed_slot_should_not_crash.<locals>.Classr   Nr   r   r   r   r;   r      r   r   r;   c                       e Zd Z j        ZdS )JTestLoadAttrCache.test_load_borrowed_slot_should_not_crash.<locals>.SneakyNr	   r
   r   r   borrowedrG   s   r   r   r              zHHHr   r   c                     | j          d S r   r   r   s    r   r    zETestLoadAttrCache.test_load_borrowed_slot_should_not_crash.<locals>.f   s    JJJJr   r!   r   r   s        @r   (test_load_borrowed_slot_should_not_crashz:TestLoadAttrCache.test_load_borrowed_slot_should_not_crash   s   	" 	" 	" 	" 	" 	" 	" 	"	" 	" 	" 	" 	" 	" 	" 	" 	" 	"	 	 	 FHHt 	 	A""9--  !              	 	r   c                      G d d           G fdd          }d } |            }t          d          D ]?}|                     t                    5   ||           d d d            n# 1 swxY w Y   @d S )Nc                       e Zd ZdZdS )JTestLoadAttrCache.test_store_borrowed_slot_should_not_crash.<locals>.Classr   Nr   r   r   r   r;   r      r   r   r;   c                       e Zd Z j        ZdS )KTestLoadAttrCache.test_store_borrowed_slot_should_not_crash.<locals>.SneakyNr   rG   s   r   r   r      r   r   r   c                     d| _         d S r   r   r   s    r   r    zFTestLoadAttrCache.test_store_borrowed_slot_should_not_crash.<locals>.f   s    AJJJr   r!   r   r   s        @r   )test_store_borrowed_slot_should_not_crashz;TestLoadAttrCache.test_store_borrowed_slot_should_not_crash   s   	" 	" 	" 	" 	" 	" 	" 	"	" 	" 	" 	" 	" 	" 	" 	" 	" 	"	 	 	 FHHt 	 	A""9--  !              	 	r   N)r	   r
   r   r/   rO   r_   ri   rr   r|   r   r   r   r   r   r   r   r   r   r   r   r   r      s        " " "*" " "8! ! !" " "," " "(# # #' ' '+ + +! ! !" " "2  $  "       r   r   c                   D    e Zd Zd Zd Zd Zd Zd Zd Zd Z	d Z
d	 Zd
S )TestLoadMethodCachec                 X    G d d           G fdd          }d }d }d } |            |_         fd}t          d	          D ]}|                      |                        |_        |_        t          d	          D ]}|                      |                        d S )
Nc                       e Zd ZdS )PTestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.DescriptorNr   r   r   r   r   r      r   r   r   c                   $    e Zd Z              ZdS )KTestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.ClassNr5   r   s   r   r;   r      r8   r   r;   c                     d S )Nc                      dS r@   r   r   r   r   r'   z_TestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.__get__.<locals>.<lambda>      5 r   r   rA   s      r   r+   zMTestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.__get__   
     = r   c                     d S r   r   r$   s      r   r,   zMTestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.__set__  rD   r   c                      dS rT   r   r   r   r   r6   zOTestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.attribute  rD   r   c                  ,                                      S r   rF   )r%   s   r   r    zGTestLoadMethodCache.test_descriptor_added_after_optimization.<locals>.f  s    %%'''r   r!   )r6   r*   rK   r+   r,   rL   )	r   r;   r+   r,   r6   r    rN   r   r%   s	          @@r   r/   z<TestLoadMethodCache.test_descriptor_added_after_optimization   s7   	 	 	 	 	 	 	 		% 	% 	% 	% 	% 	% 	% 	% 	% 	%	! 	! 	!	 	 		 	 	 577&	( 	( 	( 	( 	( t 	! 	!AOOAACC    $
$
t 	" 	"AQQSS!!!!	" 	"r   c                 Z    G d d           G fddt                     } G d d|          d }d	 }fd
}t          d          D ]}|                      |                        |_        |_        t          d          D ]}|                      |                        d S )Nc                       e Zd ZdS )ZTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.DescriptorNr   r   r   r   r   r     r   r   r   c                   $    e Zd Z              ZdS )YTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.MetaclassNr5   r   s   r   r7   r     r8   r   r7   c                       e Zd Zd ZdS )UTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.Classc                      dS rT   r   r   r   r   r6   z_TestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.Class.attribute   r   r   Nr5   r   r   r   r;   r     r   r   r;   r=   c                     d S )Nc                      dS r@   r   r   r   r   r'   ziTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.__get__.<locals>.<lambda>$  r   r   r   rA   s      r   r+   zWTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.__get__#  r   r   c                     d S r   r   r$   s      r   r,   zWTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.__set__&  rD   r   c                  ,                                      S r   rF   rG   s   r   r    zQTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization.<locals>.f)      ??$$$r   r!   rI   rM   s         @@r   rO   zFTestLoadMethodCache.test_metaclass_descriptor_added_after_optimization  sD   	 	 	 	 	 	 	 		% 	% 	% 	% 	% 	% 	% 	% 	% 	%	 	 	 	 	i 	 	 	 		! 	! 	!	 	 		% 	% 	% 	% 	% t 	! 	!AOOAACC    $
$
t 	" 	"AQQSS!!!!	" 	"r   c                      G d dt                     } G d d|          fd}t          d          D ]}|                      |                        d S )Nc                   $    e Zd Zed             ZdS )XTestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Metaclassc                     d S )Nc                      dS rT   r   r   r   r   r'   ztTestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Metaclass.attribute.<locals>.<lambda>9      t r   r   r   s    r   r6   zbTestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Metaclass.attribute7  
    #|#r   NrV   r   r   r   r7   r   6  -        $ $ X$ $ $r   r7   c                       e Zd Zd ZdS )TTestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Classc                      dS r@   r   r   r   r   r6   z^TestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.Class.attribute<      ur   Nr5   r   r   r   r;   r  ;  #            r   r;   r=   c                  ,                                      S r   rF   rG   s   r   r    zPTestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute.<locals>.f?  r   r   r!   r]   r^   s       @r   r_   zETestLoadMethodCache.test_metaclass_descriptor_shadows_class_attribute5  s    	$ 	$ 	$ 	$ 	$ 	$ 	$ 	$
	 	 	 	 	i 	 	 	 		% 	% 	% 	% 	% t 	! 	!AOOAACC    	! 	!r   c                 @    G d dt                     } G d d|          t          d             }fd}t          d          D ]}|                      |                        ||_        t          d          D ]}|                      |                        d S )	Nc                       e Zd ZdS )WTestLoadMethodCache.test_metaclass_set_descriptor_after_optimization.<locals>.MetaclassNr   r   r   r   r7   r  F  r   r   r7   c                       e Zd Zd ZdS )STestLoadMethodCache.test_metaclass_set_descriptor_after_optimization.<locals>.Classc                      dS rT   r   r   r   r   r6   z]TestLoadMethodCache.test_metaclass_set_descriptor_after_optimization.<locals>.Class.attributeJ  r   r   Nr5   r   r   r   r;   r  I  r   r   r;   r=   c                     d S )Nc                      dS r@   r   r   r   r   r'   ziTestLoadMethodCache.test_metaclass_set_descriptor_after_optimization.<locals>.attribute.<locals>.<lambda>O  r   r   r   r   s    r   r6   zWTestLoadMethodCache.test_metaclass_set_descriptor_after_optimization.<locals>.attributeM  s
     = r   c                  ,                                      S r   rF   rG   s   r   r    zOTestLoadMethodCache.test_metaclass_set_descriptor_after_optimization.<locals>.fQ  r   r   r!   rg   rh   s        @r   ri   zDTestLoadMethodCache.test_metaclass_set_descriptor_after_optimizationE  s   	 	 	 	 	 	 	 		 	 	 	 	i 	 	 	 	 
	! 	! 
	!	% 	% 	% 	% 	% t 	! 	!AOOAACC    '	t 	" 	"AQQSS!!!!	" 	"r   c                     G d dt                     } G d d|          fd}t          d          D ]}|                      |                        |`t          d          D ]}|                      |                        d S )Nc                   $    e Zd Zed             ZdS )WTestLoadMethodCache.test_metaclass_del_descriptor_after_optimization.<locals>.Metaclassc                     d S )Nc                      dS rT   r   r   r   r   r'   zsTestLoadMethodCache.test_metaclass_del_descriptor_after_optimization.<locals>.Metaclass.attribute.<locals>.<lambda>`  r   r   r   r   s    r   r6   zaTestLoadMethodCache.test_metaclass_del_descriptor_after_optimization.<locals>.Metaclass.attribute^  r  r   NrV   r   r   r   r7   r  ]  r  r   r7   c                       e Zd Zd ZdS )STestLoadMethodCache.test_metaclass_del_descriptor_after_optimization.<locals>.Classc                      dS r@   r   r   r   r   r6   z]TestLoadMethodCache.test_metaclass_del_descriptor_after_optimization.<locals>.Class.attributec  r  r   Nr5   r   r   r   r;   r  b  r  r   r;   r=   c                  ,                                      S r   rF   rG   s   r   r    zOTestLoadMethodCache.test_metaclass_del_descriptor_after_optimization.<locals>.ff  r   r   r!   rq   r^   s       @r   rr   zDTestLoadMethodCache.test_metaclass_del_descriptor_after_optimization\  s    	$ 	$ 	$ 	$ 	$ 	$ 	$ 	$
	 	 	 	 	i 	 	 	 		% 	% 	% 	% 	% t 	! 	!AOOAACC    t 	" 	"AQQSS!!!!	" 	"r   c                      G d d          fd}t          d          D ]"}|                      |            ddg           #d S )Nc                       e Zd Zd ZdS )PTestLoadMethodCache.test_type_descriptor_shadows_attribute_method.<locals>.Classc                  
    ddgS )Nr   eggsr   r   r   r   rw   zTTestLoadMethodCache.test_type_descriptor_shadows_attribute_method.<locals>.Class.mros  s    ''r   Nrv   r   r   r   r;   r  r  s#        ( ( ( ( (r   r;   c                  ,                                      S r   ry   rG   s   r   r    zLTestLoadMethodCache.test_type_descriptor_shadows_attribute_method.<locals>.fv  s    99;;r   r!   r   r  r   r{   s      @r   r|   zATestLoadMethodCache.test_type_descriptor_shadows_attribute_methodq  s    	( 	( 	( 	( 	( 	( 	( 	(	 	 	 	 	 t 	4 	4AQQSS66"23333	4 	4r   c                      G d d          fd}t          d          D ] }|                      |            d           !d S )Nc                       e Zd Zd ZdS )PTestLoadMethodCache.test_type_descriptor_shadows_attribute_member.<locals>.Classc                      dS )Nr   r   r   r   r   r   zYTestLoadMethodCache.test_type_descriptor_shadows_attribute_member.<locals>.Class.__base__~  s    vr   Nr   r   r   r   r;   r#  }  s#            r   r;   c                  ,                                      S r   r   rG   s   r   r    zLTestLoadMethodCache.test_type_descriptor_shadows_attribute_member.<locals>.f  s    >>###r   r!   r   )r*   assertNotEqualr{   s      @r   r   zATestLoadMethodCache.test_type_descriptor_shadows_attribute_member|  s    	 	 	 	 	 	 	 		$ 	$ 	$ 	$ 	$ t 	- 	-AV,,,,	- 	-r   c                      G d dt                     } G d d|          fd}t          d          D ]}|                      |                        d S )Nc                       e Zd Zd ZdS )BTestLoadMethodCache.test_metaclass_getattribute.<locals>.Metaclassc                     d S )Nc                      dS rT   r   r   r   r   r'   zeTestLoadMethodCache.test_metaclass_getattribute.<locals>.Metaclass.__getattribute__.<locals>.<lambda>  r   r   r   r   s     r   r   zSTestLoadMethodCache.test_metaclass_getattribute.<locals>.Metaclass.__getattribute__  s
    #|#r   Nr   r   r   r   r7   r)    s#        $ $ $ $ $r   r7   c                       e Zd Zd ZdS )>TestLoadMethodCache.test_metaclass_getattribute.<locals>.Classc                      dS r@   r   r   r   r   r6   zHTestLoadMethodCache.test_metaclass_getattribute.<locals>.Class.attribute  r  r   Nr5   r   r   r   r;   r-    r  r   r;   r=   c                  ,                                      S r   rF   rG   s   r   r    z:TestLoadMethodCache.test_metaclass_getattribute.<locals>.f  r   r   r!   r]   r^   s       @r   r   z/TestLoadMethodCache.test_metaclass_getattribute  s    	$ 	$ 	$ 	$ 	$ 	$ 	$ 	$	 	 	 	 	i 	 	 	 		% 	% 	% 	% 	% t 	! 	!AOOAACC    	! 	!r   c                 F    G d dt                     } G d dt                     } G d d|          fd}t          d	          D ]}|                      |                        |_        t          d	          D ]}|                      |                        d S )
Nc                   $    e Zd Zed             ZdS )=TestLoadMethodCache.test_metaclass_swap.<locals>.OldMetaclassc                     d S )Nc                      dS rT   r   r   r   r   r'   zYTestLoadMethodCache.test_metaclass_swap.<locals>.OldMetaclass.attribute.<locals>.<lambda>  r   r   r   r   s    r   r6   zGTestLoadMethodCache.test_metaclass_swap.<locals>.OldMetaclass.attribute  r  r   NrV   r   r   r   r   r2    r  r   r   c                   $    e Zd Zed             ZdS )=TestLoadMethodCache.test_metaclass_swap.<locals>.NewMetaclassc                     d S )Nc                      dS r@   r   r   r   r   r'   zYTestLoadMethodCache.test_metaclass_swap.<locals>.NewMetaclass.attribute.<locals>.<lambda>  s    u r   r   r   s    r   r6   zGTestLoadMethodCache.test_metaclass_swap.<locals>.NewMetaclass.attribute  s
    $}$r   NrV   r   r   r   r   r6    s-        % % X% % %r   r   c                       e Zd ZdS )6TestLoadMethodCache.test_metaclass_swap.<locals>.ClassNr   r   r   r   r;   r:    r   r   r;   r=   c                  ,                                      S r   rF   rG   s   r   r    z2TestLoadMethodCache.test_metaclass_swap.<locals>.f  r   r   r!   r   r   s        @r   r   z'TestLoadMethodCache.test_metaclass_swap  s   	$ 	$ 	$ 	$ 	$4 	$ 	$ 	$
	% 	% 	% 	% 	%4 	% 	% 	%
	 	 	 	 	l 	 	 	 		% 	% 	% 	% 	% t 	! 	!AOOAACC    &t 	" 	"AQQSS!!!!	" 	"r   N)r	   r
   r   r/   rO   r_   ri   rr   r|   r   r   r   r   r   r   r   r      s        " " ">" " ":! ! ! " " "." " "*	4 	4 	4	- 	- 	-! ! !" " " " "r   r   c                        e Zd Zd Zd Zd ZdS )TestCallCachec                 R    d }d|_         t          d          D ]} |             d S )Nc                      d S r   r   r   r   r   r    z1TestCallCache.test_too_many_defaults_0.<locals>.f      Dr   r   r!   __defaults__r*   r   r    rN   s      r   test_too_many_defaults_0z&TestCallCache.test_too_many_defaults_0  sF    	 	 	 !t 	 	AACCCC	 	r   c                 h    d }d|_         t          d          D ]} |d             |             d S )Nc                     d S r   r   r   s    r   r    z1TestCallCache.test_too_many_defaults_1.<locals>.f  r@  r   )NNr!   rA  rC  s      r   test_too_many_defaults_1z&TestCallCache.test_too_many_defaults_1  sS    	 	 	 &t 	 	AAdGGGACCCC	 	r   c                     d }d|_         t          d          D ]#} |d d             |d             |             $d S )Nc                     d S r   r   )r   ys     r   r    z1TestCallCache.test_too_many_defaults_2.<locals>.f  r@  r   )NNNr!   rA  rC  s      r   test_too_many_defaults_2z&TestCallCache.test_too_many_defaults_2  sb    	 	 	 ,t 	 	AAdDMMMAdGGGACCCC	 	r   N)r	   r
   r   rD  rG  rK  r   r   r   r=  r=    sA                r   r=  __main__)unittestTestCaser   r   r=  r	   mainr   r   r   <module>rP     s    q q q q q) q q qhu" u" u" u" u"(+ u" u" u"p    H%   : zOOOHMOOOOO r   