mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-11-04 13:29:12 +00:00 
			
		
		
		
	filterlib: preserve value quotes
This commit is contained in:
		
							parent
							
								
									f20f913223
								
							
						
					
					
						commit
						49e1597ea4
					
				
					 1 changed files with 8 additions and 1 deletions
				
			
		| 
						 | 
					@ -115,12 +115,19 @@ int LibertyParser::lexer(std::string &str)
 | 
				
			||||||
	// maybe it's a string?
 | 
						// maybe it's a string?
 | 
				
			||||||
	if (c == '"') {
 | 
						if (c == '"') {
 | 
				
			||||||
		str = "";
 | 
							str = "";
 | 
				
			||||||
 | 
					#ifdef FILTERLIB
 | 
				
			||||||
 | 
							str += c;
 | 
				
			||||||
 | 
					#endif
 | 
				
			||||||
		while (1) {
 | 
							while (1) {
 | 
				
			||||||
			c = f.get();
 | 
								c = f.get();
 | 
				
			||||||
			if (c == '\n')
 | 
								if (c == '\n')
 | 
				
			||||||
				line++;
 | 
									line++;
 | 
				
			||||||
			if (c == '"')
 | 
								if (c == '"') {
 | 
				
			||||||
 | 
					#ifdef FILTERLIB
 | 
				
			||||||
 | 
									str += c;
 | 
				
			||||||
 | 
					#endif
 | 
				
			||||||
				break;
 | 
									break;
 | 
				
			||||||
 | 
								}
 | 
				
			||||||
			str += c;
 | 
								str += c;
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
		// fprintf(stderr, "LEX: string >>%s<<\n", str.c_str());
 | 
							// fprintf(stderr, "LEX: string >>%s<<\n", str.c_str());
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue