mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-11-04 13:29:12 +00:00 
			
		
		
		
	Can clean boxed modules
If a selection contains a boxed module, but does not select boxes, it should be removed from the selection.
This commit is contained in:
		
							parent
							
								
									2f907e8be4
								
							
						
					
					
						commit
						3b1b09baf6
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -840,7 +840,7 @@ void RTLIL::Selection::optimize(RTLIL::Design *design)
 | 
			
		|||
 | 
			
		||||
	del_list.clear();
 | 
			
		||||
	for (auto mod_name : selected_modules) {
 | 
			
		||||
		if (current_design->modules_.count(mod_name) == 0)
 | 
			
		||||
		if (current_design->modules_.count(mod_name) == 0 || (!selects_boxes && boxed_module(mod_name)))
 | 
			
		||||
			del_list.push_back(mod_name);
 | 
			
		||||
		selected_members.erase(mod_name);
 | 
			
		||||
	}
 | 
			
		||||
| 
						 | 
				
			
			@ -849,7 +849,7 @@ void RTLIL::Selection::optimize(RTLIL::Design *design)
 | 
			
		|||
 | 
			
		||||
	del_list.clear();
 | 
			
		||||
	for (auto &it : selected_members)
 | 
			
		||||
		if (current_design->modules_.count(it.first) == 0)
 | 
			
		||||
		if (current_design->modules_.count(it.first) == 0 || (!selects_boxes && boxed_module(it.first)))
 | 
			
		||||
			del_list.push_back(it.first);
 | 
			
		||||
	for (auto mod_name : del_list)
 | 
			
		||||
		selected_members.erase(mod_name);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue