mirror of
				https://github.com/psycopg/psycopg2.git
				synced 2025-11-04 01:37:31 +03:00 
			
		
		
		
	Parens don't need escaping in regexp char classes
This commit is contained in:
		
							parent
							
								
									1332d4a0d8
								
							
						
					
					
						commit
						f782470d71
					
				| 
						 | 
					@ -849,9 +849,9 @@ class CompositeCaster(object):
 | 
				
			||||||
        return self._ctor(*attrs)
 | 
					        return self._ctor(*attrs)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    _re_tokenize = regex.compile(r"""
 | 
					    _re_tokenize = regex.compile(r"""
 | 
				
			||||||
  \(? ([,\)])                       # an empty token, representing NULL
 | 
					  \(? ([,)])                        # an empty token, representing NULL
 | 
				
			||||||
| \(? " ((?: [^"] | "")*) " [,)]    # or a quoted string
 | 
					| \(? " ((?: [^"] | "")*) " [,)]    # or a quoted string
 | 
				
			||||||
| \(? ([^",\)]+) [,\)]              # or an unquoted string
 | 
					| \(? ([^",)]+) [,)]                # or an unquoted string
 | 
				
			||||||
    """, regex.VERBOSE)
 | 
					    """, regex.VERBOSE)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    _re_undouble = regex.compile(r'(["\\])\1')
 | 
					    _re_undouble = regex.compile(r'(["\\])\1')
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user