mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-11-04 05:19:11 +00:00 
			
		
		
		
	Fixed a gcc compiler warning [-Wparentheses]
This commit is contained in:
		
							parent
							
								
									bc8d94b4ae
								
							
						
					
					
						commit
						441e5fbfca
					
				
					 1 changed files with 2 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -139,12 +139,13 @@ bool is_reg_wire(RTLIL::SigSpec sig, std::string ®_name)
 | 
			
		|||
	if (reg_wires.count(sig.chunks[0].wire->name) == 0)
 | 
			
		||||
		return false;
 | 
			
		||||
	reg_name = id(sig.chunks[0].wire->name);
 | 
			
		||||
	if (sig.width != sig.chunks[0].wire->width)
 | 
			
		||||
	if (sig.width != sig.chunks[0].wire->width) {
 | 
			
		||||
		if (sig.width == 1)
 | 
			
		||||
			reg_name += stringf("[%d]", sig.chunks[0].wire->start_offset +  sig.chunks[0].offset);
 | 
			
		||||
		else
 | 
			
		||||
			reg_name += stringf("[%d]", sig.chunks[0].wire->start_offset +  sig.chunks[0].offset + sig.chunks[0].width - 1,
 | 
			
		||||
					sig.chunks[0].wire->start_offset +  sig.chunks[0].offset);
 | 
			
		||||
	}
 | 
			
		||||
	return true;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue