mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 03:32:29 +00:00 
			
		
		
		
	Clear pkg_user_types if no packages following a 'design -reset-vlog'.
This commit is contained in:
		
							parent
							
								
									6d8d6b402f
								
							
						
					
					
						commit
						0aaa36ca6d
					
				
					 2 changed files with 5 additions and 0 deletions
				
			
		|  | @ -465,6 +465,10 @@ struct VerilogFrontend : public Frontend { | |||
| 				log("-- Verilog code after preprocessor --\n%s-- END OF DUMP --\n", code_after_preproc.c_str()); | ||||
| 			lexin = new std::istringstream(code_after_preproc); | ||||
| 		} | ||||
| 		if (design->verilog_packages.empty()) { | ||||
| 			// might be because of a `design -reset-vlog` command
 | ||||
| 			pkg_user_types.clear(); | ||||
| 		} | ||||
| 
 | ||||
| 		frontend_verilog_yyset_lineno(1); | ||||
| 		frontend_verilog_yyrestart(NULL); | ||||
|  |  | |||
|  | @ -522,6 +522,7 @@ interface: | |||
| 		ast_stack.pop_back(); | ||||
| 		log_assert(ast_stack.size() == 1); | ||||
| 		current_ast_mod = NULL; | ||||
| 		user_types.clear(); | ||||
| 	}; | ||||
| 
 | ||||
| interface_body: | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue