mirror of
				https://github.com/python/cpython.git
				synced 2025-11-03 23:21:29 +00:00 
			
		
		
		
	bpo-33534: Remove unneeded test. (GH-6897)
This condition as already tested before this code is called.
This commit is contained in:
		
							parent
							
								
									f8e7549490
								
							
						
					
					
						commit
						9285835a05
					
				
					 1 changed files with 5 additions and 6 deletions
				
			
		| 
						 | 
					@ -544,9 +544,8 @@ def _hash_fn(fields):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
def _is_classvar(a_type, typing):
 | 
					def _is_classvar(a_type, typing):
 | 
				
			||||||
    if typing:
 | 
					    # This test uses a typing internal class, but it's the best way to
 | 
				
			||||||
        # This test uses a typing internal class, but it's the best
 | 
					    # test if this is a ClassVar.
 | 
				
			||||||
        # way to test if this is a ClassVar.
 | 
					 | 
				
			||||||
    return (a_type is typing.ClassVar
 | 
					    return (a_type is typing.ClassVar
 | 
				
			||||||
            or (type(a_type) is typing._GenericAlias
 | 
					            or (type(a_type) is typing._GenericAlias
 | 
				
			||||||
                and a_type.__origin__ is typing.ClassVar))
 | 
					                and a_type.__origin__ is typing.ClassVar))
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue