mirror of
				https://github.com/bellard/quickjs.git
				synced 2025-05-29 01:49:18 +08:00 
			
		
		
		
	regexp: allow [\-] in unicode mode (#373)
This commit is contained in:
		
							parent
							
								
									1be68b3345
								
							
						
					
					
						commit
						837a697588
					
				@ -686,6 +686,10 @@ static int get_class_atom(REParseState *s, CharRange *cr,
 | 
				
			|||||||
                c = '\\';
 | 
					                c = '\\';
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
            break;
 | 
					            break;
 | 
				
			||||||
 | 
					        case '-':
 | 
				
			||||||
 | 
					            if (!inclass && s->is_unicode)
 | 
				
			||||||
 | 
					                goto invalid_escape;
 | 
				
			||||||
 | 
					            break;
 | 
				
			||||||
#ifdef CONFIG_ALL_UNICODE
 | 
					#ifdef CONFIG_ALL_UNICODE
 | 
				
			||||||
        case 'p':
 | 
					        case 'p':
 | 
				
			||||||
        case 'P':
 | 
					        case 'P':
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user