mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-10-31 11:42:30 +00:00 
			
		
		
		
	Added support for #-comments in same line as command
This commit is contained in:
		
							parent
							
								
									821156b6cf
								
							
						
					
					
						commit
						1c6dea3a0d
					
				
					 1 changed files with 2 additions and 0 deletions
				
			
		|  | @ -148,6 +148,8 @@ void Pass::call(RTLIL::Design *design, std::string command) | ||||||
| 	for (char *p = strtok_r(s, " \t\r\n", &saveptr); p; p = strtok_r(NULL, " \t\r\n", &saveptr)) { | 	for (char *p = strtok_r(s, " \t\r\n", &saveptr); p; p = strtok_r(NULL, " \t\r\n", &saveptr)) { | ||||||
| 		std::string str = p; | 		std::string str = p; | ||||||
| 		int strsz = str.size(); | 		int strsz = str.size(); | ||||||
|  | 		if (str == "#") | ||||||
|  | 			break; | ||||||
| 		if (strsz > 0 && str[strsz-1] == ';') { | 		if (strsz > 0 && str[strsz-1] == ';') { | ||||||
| 			int num_semikolon = 0; | 			int num_semikolon = 0; | ||||||
| 			while (strsz > 0 && str[strsz-1] == ';') | 			while (strsz > 0 && str[strsz-1] == ';') | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue