Ticket #4713: __init__.diff
File __init__.diff, 865 bytes (added by , 17 years ago) |
---|
-
django/template/__init__.py
96 96 # matches if the string is valid number 97 97 number_re = re.compile(r'[-+]?(\d+|\d*\.\d+)$') 98 98 99 # matches if the string is marked for translation 100 trans_re = re.compile(r'_\((\'|").*?(\'|")\)') 101 99 102 # global dictionary of libraries that have been loaded using get_library 100 103 libraries = {} 101 104 # global list of libraries to load by default for a new parser … … 661 664 if number_re.match(path): 662 665 number_type = '.' in path and float or int 663 666 current = number_type(path) 667 elif trans_re.match(path): 668 current = _(path[3:-2]) 664 669 elif path[0] in ('"', "'") and path[0] == path[-1]: 665 670 current = path[1:-1] 666 671 else: