File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -2972,11 +2972,14 @@ void RTLIL::Module::connect(const RTLIL::SigSig &conn)
29722972	//  ignore all attempts to assign constants to other constants
29732973	if  (conn.first .has_const ()) {
29742974		RTLIL::SigSig new_conn;
2975- 		for  (int  i = 0 ; i < GetSize (conn.first ); i++)
2976- 			if  (conn.first [i].wire ) {
2977- 				new_conn.first .append (conn.first [i]);
2978- 				new_conn.second .append (conn.second [i]);
2975+ 		RTLIL::SigSpecConstIterator second_it = conn.second .begin ();
2976+ 		for  (auto  &first_bit : conn.first ) {
2977+ 			if  (first_bit.wire ) {
2978+ 				new_conn.first .append (first_bit);
2979+ 				new_conn.second .append (*second_it);
29792980			}
2981+ 			++second_it;
2982+ 		}
29802983		if  (GetSize (new_conn.first ))
29812984			connect (new_conn);
29822985		return ;
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments