mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 05:31:20 +00:00 
			
		
		
		
	fix a few get_name() calls and turn then to .name
Reviewer: Christian Heimes
This commit is contained in:
		
							parent
							
								
									1cc69636ef
								
							
						
					
					
						commit
						b6a955672f
					
				
					 1 changed files with 4 additions and 4 deletions
				
			
		|  | @ -67,7 +67,7 @@ def _note(self, format, *args): | ||||||
|             if self.__verbose: |             if self.__verbose: | ||||||
|                 format = format % args |                 format = format % args | ||||||
|                 format = "%s: %s\n" % ( |                 format = "%s: %s\n" % ( | ||||||
|                     current_thread().get_name(), format) |                     current_thread().name, format) | ||||||
|                 _sys.stderr.write(format) |                 _sys.stderr.write(format) | ||||||
| 
 | 
 | ||||||
| else: | else: | ||||||
|  | @ -110,7 +110,7 @@ def __repr__(self): | ||||||
|         owner = self.__owner |         owner = self.__owner | ||||||
|         return "<%s(%s, %d)>" % ( |         return "<%s(%s, %d)>" % ( | ||||||
|                 self.__class__.__name__, |                 self.__class__.__name__, | ||||||
|                 owner and owner.get_name(), |                 owner and owner.name, | ||||||
|                 self.__count) |                 self.__count) | ||||||
| 
 | 
 | ||||||
|     def acquire(self, blocking=1): |     def acquire(self, blocking=1): | ||||||
|  | @ -534,7 +534,7 @@ def __bootstrap_inner(self): | ||||||
|                 # self. |                 # self. | ||||||
|                 if _sys: |                 if _sys: | ||||||
|                     _sys.stderr.write("Exception in thread %s:\n%s\n" % |                     _sys.stderr.write("Exception in thread %s:\n%s\n" % | ||||||
|                                       (self.get_name(), _format_exc())) |                                       (self.name, _format_exc())) | ||||||
|                 else: |                 else: | ||||||
|                     # Do the best job possible w/o a huge amt. of code to |                     # Do the best job possible w/o a huge amt. of code to | ||||||
|                     # approximate a traceback (code ideas from |                     # approximate a traceback (code ideas from | ||||||
|  | @ -542,7 +542,7 @@ def __bootstrap_inner(self): | ||||||
|                     exc_type, exc_value, exc_tb = self.__exc_info() |                     exc_type, exc_value, exc_tb = self.__exc_info() | ||||||
|                     try: |                     try: | ||||||
|                         print>>self.__stderr, ( |                         print>>self.__stderr, ( | ||||||
|                             "Exception in thread " + self.get_name() + |                             "Exception in thread " + self.name + | ||||||
|                             " (most likely raised during interpreter shutdown):") |                             " (most likely raised during interpreter shutdown):") | ||||||
|                         print>>self.__stderr, ( |                         print>>self.__stderr, ( | ||||||
|                             "Traceback (most recent call last):") |                             "Traceback (most recent call last):") | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Benjamin Peterson
						Benjamin Peterson