mirror of
				https://github.com/python/cpython.git
				synced 2025-10-30 21:21:22 +00:00 
			
		
		
		
	Issue #17940: Remove redundant code from _Section.format_help()
Output of func(*args) stored in the next line:
    item_help = join([func(*args) for func, args in self.items])
_Section.items only used by HelpFormatter._add_item() and it looks
like it doesn't have any side effects.
Patch by Yogesh Chaudhari.
			
			
This commit is contained in:
		
							parent
							
								
									d79d5b1a50
								
							
						
					
					
						commit
						841b930a41
					
				
					 1 changed files with 0 additions and 2 deletions
				
			
		|  | @ -210,8 +210,6 @@ def format_help(self): | ||||||
|             if self.parent is not None: |             if self.parent is not None: | ||||||
|                 self.formatter._indent() |                 self.formatter._indent() | ||||||
|             join = self.formatter._join_parts |             join = self.formatter._join_parts | ||||||
|             for func, args in self.items: |  | ||||||
|                 func(*args) |  | ||||||
|             item_help = join([func(*args) for func, args in self.items]) |             item_help = join([func(*args) for func, args in self.items]) | ||||||
|             if self.parent is not None: |             if self.parent is not None: | ||||||
|                 self.formatter._dedent() |                 self.formatter._dedent() | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Berker Peksag
						Berker Peksag