Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- idents = [m.span() for m in re.finditer(identifier_regexp, source)]
- strings = [m.span() for m in re.finditer(string_regexp, source)]
- idents = [(i,j) for (i,j) in idents if source[i:j] not in reserved_identifiers]
- idents = [(i,j) for (i,j) in idents if all([i<m or j>n for (m,n) in strings])]
Add Comment
Please, Sign In to add comment