PageRenderTime 246ms queryTime 23ms sortTime 18ms getByIdsTime 91ms findMatchingLines 38ms

100+ results results for 're.compile repo:bwesterb/pypy' (246 ms)

Not the results you expected?
do_dp_plots.py git://pkgs.fedoraproject.org/E | Python | 407 lines
                    
67
                    
68cvc_sc_pat    = re.compile("storecomm_[^i].*nf_ai")
                    
69cvc_scf_pat   = re.compile("storecomm_[^i].*sf_ai")
                    
69cvc_scf_pat   = re.compile("storecomm_[^i].*sf_ai")
                    
70e_sc_pat      = re.compile("storecomm_[^i].*sf_ai")
                    
71e_sc_ni_pat   = re.compile("storecomm_[^i].*sf_ni")
                    
72
                    
73cvc_si_pat  = re.compile("storeinv_[^i].*nf_ai")
                    
74cvc_sif_pat = re.compile("storeinv_[^i].*sf_ai")
                    
74cvc_sif_pat = re.compile("storeinv_[^i].*sf_ai")
                    
75e_si_pat    = re.compile("storeinv_[^i].*sf_ai")
                    
76
                    
76
                    
77cvc_sw_pat  = re.compile("swap_[^i].*nf_ai")
                    
78cvc_swf_pat = re.compile("swap_[^i].*sf_ai")
                    
                
toc.py git://github.com/quicksilver/Quicksilver.git | Python | 310 lines
                    
31
                    
32IDCOUNT_RE = re.compile(r'^(.*)_([0-9]+)$')
                    
33
                    
139
                    
140        self.header_rgx = re.compile("[Hh][123456]")
                    
141
                    
                
gitutil.py git://pkgs.fedoraproject.org/uboot-tools | Python | 391 lines
                    
90    stdout, stderr = pipe.communicate()
                    
91    re_error = re.compile('^error: patch failed: (.+):(\d+)')
                    
92    for line in stderr.splitlines():
                    
                
file_parsers.py https://github.com/woutersmet/Molmodsummer.git | Python | 375 lines
                    
71        ThermoChemParser.__init__(self, label,
                    
72            activator=re.compile("Force constants in Cartesian coordinates:"),
                    
73            deactivator=re.compile(r"^\s*\b[^0-9+\-]"),
                    
140        ThermoChemParser.__init__(self, label,
                    
141            activator=re.compile("Temperature\s+\S+\s+Kelvin.\s+Pressure\s+\S+\s+Atm."),
                    
142            deactivator=re.compile("Molecular mass:\s+\S+\s+amu."),
                    
144        )
                    
145        self.re = re.compile("Atom\s*\d+\s+has atomic number\s+\d+\s+and mass\s+(?P<mass>\S+)")
                    
146
                    
168        ThermoChemParser.__init__(self, label, activator, deactivator, condition)
                    
169        self.re = re.compile("\d+\s+\d+\s+(?P<fx>\S+)\s+(?P<fy>\S+)\s+(?P<fz>\S+)")
                    
170
                    
196        GradientParser.__init__(self, label,
                    
197            activator=re.compile("\*\*\*\*\* Axes restored to original set \*\*\*\*\*"),
                    
198            deactivator=re.compile("Cartesian Forces:"),
                    
                
SimpleJSONRPCServer.py http://apple-tv2-xbmc.googlecode.com/svn/trunk/ | Python | 283 lines
                    
159#        try:
                    
160#            urlParts = re.compile(r'/(.+?)/(.+?)\?(.*)').findall(self.path)
                    
161#            self.path = '/' + urlParts[0][0]
                    
                
SpecRuntimeModule.java git://github.com/bmwcarit/Jnario.git | Java | 360 lines
                    
13
                    
14import org.eclipse.xtend.core.compiler.UnicodeAwarePostProcessor;
                    
15import org.eclipse.xtend.core.compiler.XtendGenerator;
                    
15import org.eclipse.xtend.core.compiler.XtendGenerator;
                    
16import org.eclipse.xtend.core.compiler.XtendOutputConfigurationProvider;
                    
17import org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler;
                    
                
term.py https://bitbucket.org/thomaswaldmann/moin-2.0-dev/ | Python | 459 lines
                    
228            flags = flags | re.IGNORECASE
                    
229        _needle_re = re.compile(re.escape(needle), flags)
                    
230        TextRE.__init__(self, _needle_re)
                    
247            flags = flags | re.IGNORECASE
                    
248        _needle_re = re.compile('\\b' + re.escape(needle) + '\\b', flags)
                    
249        TextRE.__init__(self, _needle_re)
                    
266            flags = flags | re.IGNORECASE
                    
267        _needle_re = re.compile('\\b' + re.escape(needle), flags)
                    
268        TextRE.__init__(self, _needle_re)
                    
285            flags = flags | re.IGNORECASE
                    
286        _needle_re = re.compile(re.escape(needle) + '\\b', flags)
                    
287        TextRE.__init__(self, _needle_re)
                    
324            flags = flags | re.IGNORECASE
                    
325        _needle_re = re.compile(re.escape(needle), flags)
                    
326        NameRE.__init__(self, _needle_re)
                    
                
aci.py git://pkgs.fedoraproject.org/freeipa | Python | 333 lines
                    
26# Break the ACI into 3 pieces: target, name, permissions/bind_rules
                    
27ACIPat = re.compile(r'\(version\s+3.0\s*;\s*acl\s+\"([^\"]*)\"\s*;\s*([^;]*);\s*\)', re.UNICODE)
                    
28
                    
29# Break the permissions/bind_rules out
                    
30PermPat = re.compile(r'(\w+)\s*\((.*)\)\s+(.*)', re.UNICODE)
                    
31
                    
32# Break the bind rule out
                    
33BindPat = re.compile(r'([a-zA-Z0-9;\.]+)\s*(\!?=)\s*(.*)', re.UNICODE)
                    
34
                    
                
test_unicode_jy.py git://github.com/nriley/jython.git | Python | 182 lines
                    
16        # forcing the basic plane
                    
17        chunker = re.compile(r'(.*?)(["\\\x00-\x1f])', re.VERBOSE | re.MULTILINE | re.DOTALL)
                    
18        orig = u'z\U0001d120x'
                    
                
default.py git://github.com/heynemann/skink.git | Python | 375 lines
                    
19
                    
20AUTOCOMMIT_REGEXP = re.compile(r'\s*(?:UPDATE|INSERT|CREATE|DELETE|DROP|ALTER)',
                    
21                               re.I | re.UNICODE)
                    
                
peerReviewBrowser.py git://pkgs.fedoraproject.org/trac-peerreview-plugin | Python | 283 lines
                    
27
                    
28IMG_RE = re.compile(r"\.(gif|jpg|jpeg|png)(\?.*)?$", re.IGNORECASE)
                    
29
                    
31
                    
32DIGITS = re.compile(r'[0-9]+')
                    
33def _natural_order(x, y):
                    
                
breakage2tst.py git://git.savannah.gnu.org/gnugo.git | Python | 204 lines
                    
82		current_line = tstlines.pop(0)
                    
83		command_pattern = re.compile("^%d " % number)
                    
84
                    
                
debtags.py git://pkgs.fedoraproject.org/python-debian | Python | 506 lines
                    
22def parse_tags(input):
                    
23	lre = re.compile(r"^(.+?)(?::?\s*|:\s+(.+?)\s*)$")
                    
24	for line in input:
                    
193		fcoll = DB()
                    
194		tofacet = re.compile(r"^([^:]+).+")
                    
195		for pkg, tags in self.iter_packagesTags():
                    
                
etree.py git://github.com/chromium/chromium.git | Python | 340 lines
                    
13
                    
14tag_regexp = re.compile("{([^}]*)}(.*)")
                    
15
                    
                
pyini.py http://uliweb.googlecode.com/svn/trunk/ | Python | 419 lines
                    
45
                    
46r_encoding = re.compile(r'\s*coding\s*[=:]\s*([-\w.]+)')
                    
47__default_env__ = {}
                    
                
wordTranslator.py http://nltk.googlecode.com/svn/trunk/ | Python | 419 lines
                    
134			if len(english_tokens) > 0 and len(german_tokens) > 0:
                    
135				doc_regexp = re.compile(r'<DOC')
                    
136				if doc_regexp.match(english_tokens[0].type()) \
                    
179		# non-word characters 
                    
180		punct_regexp = re.compile(r'[^a-zA-Z0-9]*$')
                    
181		if punct_regexp.match(word):
                    
                
runtime-gdb.py https://code.google.com/p/gofy/ | Python | 399 lines
                    
32
                    
33	pattern = re.compile(r'^struct string$')
                    
34
                    
47
                    
48	pattern = re.compile(r'^struct \[\]')
                    
49
                    
71
                    
72	pattern = re.compile(r'^struct hash<.*>$')
                    
73
                    
111
                    
112	pattern = re.compile(r'^struct hchan<.*>$')
                    
113
                    
                
serializer.py git://github.com/django/django.git | Python | 340 lines
                    
224        # same implicit and explicit flags aren't equal.
                    
225        flags = self.value.flags ^ re.compile('').flags
                    
226        regex_flags, flag_imports = serializer_factory(flags).serialize()
                    
230            args.append(regex_flags)
                    
231        return "re.compile(%s)" % ', '.join(args), imports
                    
232
                    
                
python.mustache git://github.com/jonswar/perl-code-tidyall.git | Mustache | 1322 lines
                    
60        cls.default_options = default_options
                    
61        cls.wrapregex = re.compile('^(.+)$', re.MULTILINE)
                    
62
                    
                
gexpose.py git://github.com/nriley/jython.git | Python | 644 lines
                    
19#          group 2 = "hello"
                    
20modif_re = re.compile(r"(?:\(([\w,]+)\))?(\w+)")
                    
21
                    
26# tg = descriptive argument name (the "I'm anything but a curly brace in o{I'm anything but a curly brace} )
                    
27ktg_re = re.compile("(?P<k>\w)(?P<opt>\?(:?\((?P<dfl>[^)]*)\))?)?(?:\{(?P<tg>[^}]*)\})?")
                    
28
                    
                
jython.java git://github.com/nriley/jython.git | Java | 525 lines
                    
16import org.python.core.CodeFlag;
                    
17import org.python.core.CompileMode;
                    
18import org.python.core.Options;
                    
                
Module.java git://github.com/nriley/jython.git | Java | 673 lines
                    
22import org.python.core.CodeLoader;
                    
23import org.python.core.CompilerFlags;
                    
24import org.python.core.Py;
                    
396                                 ScopeInfo scope,
                    
397                                 org.python.core.CompilerFlags cflags)
                    
398        throws Exception
                    
                
CodeCompiler.java git://github.com/nriley/jython.git | Java | 2443 lines
                    
73import org.python.antlr.base.stmt;
                    
74import org.python.core.CompilerFlags;
                    
75import org.python.core.ContextGuard;
                    
                
spark.py git://github.com/nriley/jython.git | Python | 840 lines
                    
41        pattern = self.reflect()
                    
42        self.re = re.compile(pattern, re.VERBOSE|flags)
                    
43
                    
                
test_tempfile.py git://github.com/nriley/jython.git | Python | 708 lines
                    
42
                    
43    str_check = re.compile(r"[a-zA-Z0-9_-]{6}$")
                    
44
                    
                
test_re.py git://github.com/nriley/jython.git | Python | 802 lines
                    
21        s = 'QabbbcR'
                    
22        x = re.compile('ab+c')
                    
23        y = proxy(x)
                    
226
                    
227        pat = re.compile('((a)|(b))(c)?')
                    
228        self.assertEqual(pat.match('a').groups(), ('a', 'a', None, None))
                    
240
                    
241        pat = re.compile('(?:(?P<a1>a)|(?P<b2>b))(?P<c3>c)?')
                    
242        self.assertEqual(pat.match('a').group(1, 2, 3), ('a', None, None))
                    
263        # Tests for bug #1177831: exercise groups other than the first group
                    
264        p = re.compile('(?P<g1>a)(?P<g2>b)?((?(g2)c|d))')
                    
265        self.assertEqual(p.match('abc').groups(),
                    
                
test_optparse.py git://github.com/nriley/jython.git | Python | 1644 lines
                    
36
                    
37retype = type(re.compile(''))
                    
38
                    
                
util.py git://github.com/nriley/jython.git | Python | 516 lines
                    
65        osname = "cygwin"
                    
66        rel_re = re.compile (r'[\d.]+')
                    
67        m = rel_re.match(release)
                    
263    global _wordchars_re, _squote_re, _dquote_re
                    
264    _wordchars_re = re.compile(r'[^\\\'\"%s ]*' % string.whitespace)
                    
265    _squote_re = re.compile(r"'(?:[^'\\]|\\.)*'")
                    
265    _squote_re = re.compile(r"'(?:[^'\\]|\\.)*'")
                    
266    _dquote_re = re.compile(r'"(?:[^"\\]|\\.)*"')
                    
267
                    
                
pydoc.py git://github.com/nriley/jython.git | Python | 2261 lines
                    
121
                    
122_re_stripid = re.compile(r' at 0x[0-9a-f]{6,16}(>+)$', re.IGNORECASE)
                    
123def stripid(text):
                    
                
dbexts.py git://github.com/nriley/jython.git | Python | 726 lines
                    
127
                    
128comments = lambda x: re.compile("{.*?}", re.S).sub("", x, 0)
                    
129
                    
                
JnarioStandaloneCompiler.java git://github.com/bmwcarit/Jnario.git | Java | 301 lines
                    
32import org.eclipse.emf.ecore.resource.URIConverter;
                    
33import org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler;
                    
34import org.eclipse.xtext.ISetup;
                    
                
JnarioCompiler.java git://github.com/bmwcarit/Jnario.git | Java | 456 lines
                    
20import org.eclipse.emf.ecore.EObject;
                    
21import org.eclipse.xtend.core.compiler.XtendCompiler;
                    
22import org.eclipse.xtext.common.types.JvmGenericType;
                    
                
mvndep.py git://github.com/hudec/sql-processor.git | Python | 1236 lines
                    
33
                    
34SUBST_VER_RE = re.compile(r'{(?P<version>.+)}')
                    
35VER_RE = re.compile(r'<version>(?P<version>.+)</version>')
                    
35VER_RE = re.compile(r'<version>(?P<version>.+)</version>')
                    
36PROPS_START_RE = re.compile(r'<properties>')
                    
37PROPS_END_RE = re.compile(r'</properties>')
                    
37PROPS_END_RE = re.compile(r'</properties>')
                    
38PROPS_VERSION_RE = re.compile(r'<version(?P<name>.+)>.+</version.+>')
                    
39PARENT_START_RE = re.compile(r'<parent>')
                    
39PARENT_START_RE = re.compile(r'<parent>')
                    
40PARENT_END_RE = re.compile(r'</parent>')
                    
41GROUP_ID_RE = re.compile(r'<groupId>(?P<group>.+)</groupId>')
                    
41GROUP_ID_RE = re.compile(r'<groupId>(?P<group>.+)</groupId>')
                    
42ARTIFACT_ID_RE = re.compile(r'<artifactId>(?P<artifact>.+)</artifactId>')
                    
43VERSION_RE = re.compile(r'<version>(?P<version>.+)</version>')
                    
                
set_versions.py git://github.com/WindowsAzure/azure-sdk-for-java.git | Python | 443 lines
                    
51# The regex string we want should be the anchored one since the entire string is what's being matched
                    
52version_regex_named = re.compile(version_regex_str_with_names_anchored)
                    
53prerelease_regex_named = re.compile(prerelease_version_regex_with_name)
                    
53prerelease_regex_named = re.compile(prerelease_version_regex_with_name)
                    
54prerelease_data_regex = re.compile(prerelease_data_version_regex)
                    
55
                    
                
type.py http://hadesmem.googlecode.com/svn/trunk/ | Python | 0 lines
                    
19
                    
20__re_hyphen = re.compile ('-')
                    
21
                    
                
adapter_mediaminerorg.py https://code.google.com/p/fanficdownloader/ | Python | 238 lines
                    
92        # Find authorid and URL from... author url.
                    
93        a = soup.find('a', href=re.compile(r"/fanfic/src.php/u/\d+"))
                    
94        self.story.setMetadata('authorId',a['href'].split('/')[-1])
                    
144        # <a href="/fanfic/src.php/a/567">Ranma 1/2</a>
                    
145        for a in soup.findAll('a',href=re.compile(r"^/fanfic/src.php/a/")):
                    
146            self.story.addToList('category',a.string)
                    
149        # <a href="/fanfic/src.php/a/567">Ranma 1/2</a>
                    
150        for a in soup.findAll('a',href=re.compile(r"^/fanfic/src.php/g/")):
                    
151            self.story.addToList('genre',a.string)
                    
                
html2text.py https://code.google.com/p/fanficdownloader/ | Python | 454 lines
                    
16import urlparse
                    
17sgmllib.charref = re.compile('&#([xX]?[0-9a-fA-F]+)[^0-9a-fA-F]')
                    
18
                    
84
                    
85r_unescape = re.compile(r"&(#?[xX]?(?:[0-9a-fA-F]+|\w{1,8}));")
                    
86def unescape(s):
                    
                
lexer.py https://code.google.com/p/python-sqlparse/ | Python | 324 lines
                    
80            try:
                    
81                rex = re.compile(tdef[0], rflags).match
                    
82            except Exception, err:
                    
                
doc_helper.py git://github.com/msanders/autopy.git | Python | 371 lines
                    
98    # parser for this.
                    
99    get_comments.regex = re.compile(r'/\*\s*(.+?)\s*\*/', re.DOTALL)
                    
100    comments = {}
                    
131
                    
132    format_comment.needles = [(re.compile(r'\|(.+?)\|'), r'<var>\1</var>'),
                    
133                              (re.compile(r'\b(integer|double|float|char|'
                    
135                               r'<keyword>\1</keyword>\2'),
                    
136                              (re.compile(r'\b(True|False|None)\b'),
                    
137                               r'<const>\1</const>'),
                    
137                               r'<const>\1</const>'),
                    
138                              (re.compile('`(.+?)`'), r'<mono>\1</mono>'),
                    
139               (re.compile(r'\n[\t ]+'), ' '), # Extraneous whitespace
                    
139               (re.compile(r'\n[\t ]+'), ' '), # Extraneous whitespace
                    
140               (re.compile(r'^ ', re.M), '\n'), # Intentional linebreaks
                    
141                              ]
                    
                
JSLiteParser.py http://raft.googlecode.com/svn/trunk/ | Python | 287 lines
                    
37        self._comments = []
                    
38        self.re_octal_digits = re.compile('[0-7]{3}')
                    
39        self.re_escape_string = re.compile(r'\\(?:[0-7]{3}|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|.)')
                    
39        self.re_escape_string = re.compile(r'\\(?:[0-7]{3}|x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|.)')
                    
40        self.re_identifier = re.compile(r'^[$_a-zA-Z0-9.]+$')
                    
41        self.re_keywords = re.compile(r'^(?:break|case|catch|const|continue|debugger|default|delete|do|else|enum|false|finally|for|function|if|in|instanceof|new|null|return|switch|this|throw|true|try|typeof|var|void|while|with)$')
                    
41        self.re_keywords = re.compile(r'^(?:break|case|catch|const|continue|debugger|default|delete|do|else|enum|false|finally|for|function|if|in|instanceof|new|null|return|switch|this|throw|true|try|typeof|var|void|while|with)$')
                    
42        self.re_no_regex_start = re.compile(r'[\]]')
                    
43        self.re_space = re.compile(r'\s')
                    
                
proxy.py git://pkgs.fedoraproject.org/sagator | Python | 318 lines
                    
58
                    
59reg_http_whost=re.compile('^'+METHODS+' +'+URI+' +'+HTTP_VER+'\r?$').search
                    
60reg_http_nohost=re.compile('^'+METHODS+' +'+DIR+' +'+HTTP_VER+'\r?$').search
                    
60reg_http_nohost=re.compile('^'+METHODS+' +'+DIR+' +'+HTTP_VER+'\r?$').search
                    
61reg_hostport=re.compile(HOST_PORT).search
                    
62reg_hdr_line=re.compile('^([!-9;-~]+): *(.+?)\r?$',re.M).search
                    
62reg_hdr_line=re.compile('^([!-9;-~]+): *(.+?)\r?$',re.M).search
                    
63reg_chunk=re.compile('^([0-9A-Fa-f]+)(;.*?|)\r?$').search
                    
64reg_response=re.compile('^'+HTTP_VER+' +([0-9]{3}) +(.*)$').search
                    
                
marshal.py http://nltk.googlecode.com/svn/trunk/ | Python | 207 lines
                    
75        
                    
76        pattern = re.compile(r'^(.+):(.+?)$', re.UNICODE)
                    
77        for line in handler.readlines():
                    
121        
                    
122        pattern = re.compile(r'^(.+):(.+?)$', re.UNICODE)
                    
123        for line in lines[2:]:
                    
173        
                    
174        pattern = re.compile(r'^\[(.+)\]:(.+):(.+?)$', re.UNICODE)
                    
175        
                    
182        context_pattern_str = r'^(.+?)%s$' % ( r':(.+?)' * (self._n-2) )
                    
183        context_pattern = re.compile(context_pattern_str, re.UNICODE)
                    
184        
                    
                
logparser.py https://bitbucket.org/pypy/pypy/ | Python | 439 lines
                    
29    color = "(?:\x1b.*?m)?"
                    
30    r_start = re.compile(color + r"\[([0-9a-fA-F]+)\] \{([\w-]+)" + color + "$")
                    
31    r_stop  = re.compile(color + r"\[([0-9a-fA-F]+)\] ([\w-]+)\}" + color + "$")
                    
                
basic.py git://pkgs.fedoraproject.org/sagator | Python | 347 lines
                    
70  def reg_compile(self,arg):
                    
71      return re.compile(arg,self.flags)
                    
72  def scanbuffer(self,buffer,args={}):
                    
159  def reg_compile(self,arg):
                    
160      return re.compile(arg,self.flags)
                    
161  def scanbuffer(self,buffer,args={}):
                    
309      for vname,reg in magics.items():
                    
310        self.magics[vname]=re.compile(reg,flags)
                    
311  def __del__(self):
                    
                
megavideo.py http://dmd-xbmc.googlecode.com/svn/trunk/ | Python | 311 lines
                    
27	if mega.startswith('http://wwwstatic.megavideo.com'):
                    
28		mega = re.compile('.*v=(.+?)$').findall(mega)
                    
29		mega = mega[0]
                    
30	if mega.startswith('http://www.megavideo.com/v/'):
                    
31		mega = re.compile('.*/v/(.+?)$').findall(mega)
                    
32		mega = mega[0][0:8]
                    
97    try:
                    
98        s = re.compile(' s="(.+?)"').findall(data)
                    
99        k1 = re.compile(' k1="(.+?)"').findall(data)
                    
99        k1 = re.compile(' k1="(.+?)"').findall(data)
                    
100        k2 = re.compile(' k2="(.+?)"').findall(data)
                    
101        un = re.compile(' un="(.+?)"').findall(data)
                    
113    print("[megavideo.py] HD Link")
                    
114    hd = re.compile(' hd="(.+?)"').findall(data)
                    
115    if len(hd)>0 and hd[0]=="1":
                    
                
Terminal.py git://pkgs.fedoraproject.org/python-4Suite-XML | Python | 303 lines
                    
174    # ANSI Set Display Mode: ESC[#;...;#m
                    
175    _ansi_sdm = re.compile('\033\\[([0-9]+)(?:;([0-9]+))*m')
                    
176
                    
                
quoprimime.py git://github.com/IronLanguages/main.git | Python | 336 lines
                    
56
                    
57hqre = re.compile(r'[^-a-zA-Z0-9!*+/ ]')
                    
58bqre = re.compile(r'[^ !-<>-~\t]')
                    
                
qthelp.py https://bitbucket.org/birkenfeld/sphinx/ | Python | 298 lines
                    
26
                    
27_idpattern = re.compile(
                    
28    r'(?P<title>.+) (\((class in )?(?P<id>[\w\.]+)( (?P<descr>\w+))?\))$')
                    
                
HTMLParser.py git://github.com/IronLanguages/main.git | Python | 393 lines
                    
15
                    
16interesting_normal = re.compile('[&<]')
                    
17interesting_cdata = re.compile(r'<(/|\Z)')
                    
17interesting_cdata = re.compile(r'<(/|\Z)')
                    
18incomplete = re.compile('&[a-zA-Z#]')
                    
19
                    
19
                    
20entityref = re.compile('&([a-zA-Z][-.a-zA-Z0-9]*)[^a-zA-Z0-9]')
                    
21charref = re.compile('&#(?:[0-9]+|[xX][0-9a-fA-F]+)[^0-9a-fA-F]')
                    
22
                    
23starttagopen = re.compile('<[a-zA-Z]')
                    
24piclose = re.compile('>')
                    
24piclose = re.compile('>')
                    
25commentclose = re.compile(r'--\s*>')
                    
26tagfind = re.compile('[a-zA-Z][-.a-zA-Z0-9:_]*')
                    
                
JavaCodeFormatterFacade.java http://eclipse-code-formatter-intellij-plugin.googlecode.com/svn/ | Java | 139 lines
                    
116        // TODO: Ideally, the IntelliJ project's language level should be the default value.
                    
117        defaultConfig.setProperty("org.eclipse.jdt.core.compiler.source", "1.5");
                    
118        return defaultConfig;
                    
122    protected void validateConfig(Properties config) {
                    
123        String sourceVersionString = config.getProperty("org.eclipse.jdt.core.compiler.source");
                    
124        if (sourceVersionString != null) {
                    
128            } catch (NumberFormatException e) {
                    
129                throw new RuntimeException("Illegal value for org.eclipse.jdt.core.compiler.source property ("
                    
130                        + sourceVersionString + ") - supported Java source versions are 1.5, 1.6, 1.7, or 1.8.");
                    
132            if (sourceVersion < 1.5) {
                    
133                throw new RuntimeException("Illegal value for org.eclipse.jdt.core.compiler.source property ("
                    
134                        + sourceVersionString + ") - Eclipse formatter requires a Java source version >= 1.5.");
                    
                
convert-ly.py git://git.savannah.gnu.org/lilypond.git | Python | 391 lines
                    
40lilypond_version_re_str = '\\\\version *\"([0-9.]+)"'
                    
41lilypond_version_re = re.compile (lilypond_version_re_str)
                    
42
                    
43lilypond_version_strict_re_str = '\\\\version *\"([0-9]+[.][0-9]+[.][0-9]+)"'
                    
44lilypond_version_strict_re = re.compile (lilypond_version_strict_re_str)
                    
45
                    
                
ezt.py http://pytof.googlecode.com/svn/trunk/ | Python | 207 lines
                    
37
                    
38_re_parse = re.compile('(\[[-\w.# ]+\])|(\[\[\])')
                    
39
                    
                
PRESUBMIT.py git://github.com/chromium/chromium.git | Python | 311 lines
                    
65
                    
66    expression = re.compile("(%s|%s)%s" %
                    
67        (abs_without_prefix, fabs_without_prefix, no_nolint))
                    
255
                    
256  problem_re = input_api.re.compile(
                    
257      r'(' + base_time_type_pattern + r')|(' + base_time_member_pattern + r')')
                    
257      r'(' + base_time_type_pattern + r')|(' + base_time_member_pattern + r')')
                    
258  exception_re = input_api.re.compile(
                    
259      r'(' + using_base_time_decl_pattern + r')|(' +
                    
                
TemplateCompiler.java git://github.com/greenlaw110/Rythm.git | Java | 346 lines
                    
31import org.rythmengine.logger.Logger;
                    
32import org.eclipse.jdt.core.compiler.IProblem;
                    
33import org.eclipse.jdt.internal.compiler.*;
                    
                
sqlite.py https://code.google.com/p/web2py/ | Python | 281 lines
                    
43    def web2py_regexp(expression, item):
                    
44        return re.compile(expression).search(item) is not None
                    
45
                    
                
Scrubber.py https://mailman.svn.sourceforge.net/svnroot/mailman | Python | 310 lines
                    
41# Path characters for common platforms
                    
42pre = re.compile(r'[/\\:]')
                    
43# All other characters to strip out of Content-Disposition: filenames
                    
44# (essentially anything that isn't an alphanum, dot, slash, or underscore.
                    
45sre = re.compile(r'[^-\w.]')
                    
46
                    
                
xbb_search.py git://github.com/biopython/biopython.git | Python | 196 lines
                    
52        self.rx_pattern = self.IUPAC2regex(pattern)
                    
53        self.rx = re.compile(self.rx_pattern)
                    
54
                    
                
profile.py https://bitbucket.org/bbangert/dozer/ | Python | 340 lines
                    
36        self.profile_path = profile_path
                    
37        self.ignored_paths = map(re.compile, ignored_paths)
                    
38        tmpl_dir = os.path.join(here_dir, 'templates')
                    
                
logparser.py git://pkgs.fedoraproject.org/dblatex | Python | 360 lines
                    
20
                    
21    re_loghead = re.compile("This is [0-9a-zA-Z-]*(TeX|Omega)")
                    
22    re_rerun = re.compile(
                    
23        "(LaTeX|Package longtable|Package bibtopic) Warning:.*Rerun")
                    
24    re_rerun2 = re.compile("\(Changebar\).*Rerun")
                    
25    re_file = re.compile("(\\((?P<file>[^ \n\t(){}]*)|\\))")
                    
25    re_file = re.compile("(\\((?P<file>[^ \n\t(){}]*)|\\))")
                    
26    re_badbox = re.compile(r"(Ov|Und)erfull \\[hv]box ")
                    
27    re_line = re.compile(r"(l\.(?P<line>[0-9]+)( (?P<code>.*))?$|<\*>)")
                    
27    re_line = re.compile(r"(l\.(?P<line>[0-9]+)( (?P<code>.*))?$|<\*>)")
                    
28    re_cseq = re.compile(r".*(?P<seq>\\[^ ]*) ?$")
                    
29    re_page = re.compile("\[(?P<num>[0-9]+)\]")
                    
29    re_page = re.compile("\[(?P<num>[0-9]+)\]")
                    
30    re_atline = re.compile(
                    
31    "( detected| in paragraph)? at lines? (?P<line>[0-9]*)(--(?P<last>[0-9]*))?")
                    
                
ColorDelegator.py https://bitbucket.org/mirror/cpython/ | Python | 265 lines
                    
31
                    
32prog = re.compile(make_pat(), re.S)
                    
33idprog = re.compile(r"\s+(\w+)", re.S)
                    
33idprog = re.compile(r"\s+(\w+)", re.S)
                    
34asprog = re.compile(r".*?\b(as)\b")
                    
35
                    
                
ListIndent.py git://pkgs.fedoraproject.org/python-spiffgtkwidgets | Python | 288 lines
                    
17
                    
18bullet_point_re = re.compile(r'^(?:\d+\.|[\*\-])$')
                    
19
                    
                
_Date_pl.py git://pkgs.fedoraproject.org/gramps | Python | 316 lines
                    
158        DateParser.init_strings(self)
                    
159        self._span  = re.compile("(od)\s+(?P<start>.+)\s+(do)\s+(?P<stop>.+)", re.IGNORECASE)
                    
160        # Also handle a common mistakes
                    
160        # Also handle a common mistakes
                    
161        self._range = re.compile(u"((?:po)?mi(?:?|e)dzy)\s+(?P<start>.+)\s+(a)\s+(?P<stop>.+)", re.IGNORECASE)
                    
162        self._text2 = re.compile('(\d+)?.?\s+?%s\s*((\d+)(/\d+)?)?' % self._mon_str,
                    
163                                 re.IGNORECASE)
                    
164        self._jtext2 = re.compile('(\d+)?.?\s+?%s\s*((\d+)(/\d+)?)?' % self._jmon_str,
                    
165                                 re.IGNORECASE)
                    
                
eol.py https://bitbucket.org/mirror/mercurial/ | Python | 351 lines
                    
100# Matches a lone LF, i.e., one that is not part of CRLF.
                    
101singlelf = re.compile('(^|[^\r])\n')
                    
102# Matches a single EOL which can either be a CRLF where repeated CR
                    
104# stray CR is an error.
                    
105eolre = re.compile('\r*\n')
                    
106
                    
                
d.py git://pkgs.fedoraproject.org/guitarix | Python | 369 lines
                    
100		self.allnames=[]
                    
101		self.re_module=re.compile("module\s+([^;]+)")
                    
102		self.re_import=re.compile("import\s+([^;]+)")
                    
102		self.re_import=re.compile("import\s+([^;]+)")
                    
103		self.re_import_bindings=re.compile("([^:]+):(.*)")
                    
104		self.re_import_alias=re.compile("[^=]+=(.+)")
                    
                
base.py https://bitbucket.org/mirror/django/ | Python | 322 lines
                    
37# http://dev.mysql.com/doc/refman/5.0/en/news.html .
                    
38server_version_re = re.compile(r'(\d{1,2})\.(\d{1,2})\.(\d{1,2})')
                    
39
                    
                
managers.py git://github.com/bread-and-pepper/django-userena.git | Python | 314 lines
                    
22
                    
23SHA1_RE = re.compile('^[a-f0-9]{40}$')
                    
24
                    
                
hotline.py https://code.google.com/p/ardj/ | Python | 375 lines
                    
32
                    
33fn_filter = re.compile('wav|mp3|ogg', re.I)
                    
34
                    
                
site.py https://bitbucket.org/rblank/hgsite | Python | 410 lines
                    
80            if len(parts) == 1:
                    
81                patterns[key] = re.compile(value)
                    
82                config.setdefault(key, {})
                    
                
ColorDelegator.py https://bitbucket.org/pypy/pypy/ | Python | 259 lines
                    
33
                    
34prog = re.compile(make_pat(), re.S)
                    
35idprog = re.compile(r"\s+(\w+)", re.S)
                    
                
head.py git://github.com/sbp/phenny.git | Python | 189 lines
                    
67
                    
68r_title = re.compile(r'(?ims)<title[^>]*>(.*?)</title\s*>')
                    
69r_entity = re.compile(r'&[A-Za-z0-9#]+;')
                    
                
Article_Builder.py git://pkgs.fedoraproject.org/sugar-infoslicer | Python | 243 lines
                    
52        has_shortdesc = True
                    
53    taglist = input.findAll(re.compile("refbody|section|p|ph|image"))
                    
54    for i in xrange(len(taglist)):
                    
                
nltk.corpus.reader.pl196x-module.html http://nltk.googlecode.com/svn/trunk/ | HTML | 213 lines
                    
114    </td><td class="summary">
                    
115        <a name="PARA"></a><span class="summary-name">PARA</span> = <code title="re.compile(r'&lt;p(?: [^&gt;]*)?&gt;(.*?)&lt;/p&gt;')">re.compile(r'&lt;p<code class="re-group">(?:</code> <code class="re-group">[^</code>&gt;<code class="re-group">]</code><code class="re-op">*</code><code class="re-group">)</code><code class="re-op">?</code>&gt;<code class="re-group">(</code>.<code class="re-op">*?</code><code class="re-group">)</code>&lt;/p&gt;')</code>
                    
116    </td>
                    
121    </td><td class="summary">
                    
122        <a name="SENT"></a><span class="summary-name">SENT</span> = <code title="re.compile(r'&lt;s(?: [^&gt;]*)?&gt;(.*?)&lt;/s&gt;')">re.compile(r'&lt;s<code class="re-group">(?:</code> <code class="re-group">[^</code>&gt;<code class="re-group">]</code><code class="re-op">*</code><code class="re-group">)</code><code class="re-op">?</code>&gt;<code class="re-group">(</code>.<code class="re-op">*?</code><code class="re-group">)</code>&lt;/s&gt;')</code>
                    
123    </td>
                    
128    </td><td class="summary">
                    
129        <a name="TAGGEDWORD"></a><span class="summary-name">TAGGEDWORD</span> = <code title="re.compile(r'&lt;([wc](?: [^&gt;]*)?&gt;)(.*?)&lt;/[wc]&gt;')">re.compile(r'&lt;<code class="re-group">(</code><code class="re-group">[</code>wc<code class="re-group">]</code><code class="re-group">(?:</code> <code class="re-group">[^</code>&gt;<code class="re-group">]</code><code class="re-op">*</code><code class="re-group">)</code><code class="re-op">?</code>&gt;<code class="re-group">)</code><code class="re-group">(</code>.<code class="re-op">*?</code><code class="re-group">)</code>&lt;/<code class="re-group">[</code>wc<code class="re-group">]</code>&gt;')</code>
                    
130    </td>
                    
135    </td><td class="summary">
                    
136        <a name="WORD"></a><span class="summary-name">WORD</span> = <code title="re.compile(r'&lt;[wc](?: [^&gt;]*)?&gt;(.*?)&lt;/[wc]&gt;')">re.compile(r'&lt;<code class="re-group">[</code>wc<code class="re-group">]</code><code class="re-group">(?:</code> <code class="re-group">[^</code>&gt;<code class="re-group">]</code><code class="re-op">*</code><code class="re-group">)</code><code class="re-op">?</code>&gt;<code class="re-group">(</code>.<code class="re-op">*?</code><code class="re-group">)</code>&lt;/<code class="re-group">[</code>wc<code class="re-group">]</code>&gt;')</code>
                    
137    </td>
                    
142    </td><td class="summary">
                    
143        <a name="TYPE"></a><span class="summary-name">TYPE</span> = <code title="re.compile(r'type=&quot;(.*?)&quot;')">re.compile(r'type=&quot;<code class="re-group">(</code>.<code class="re-op">*?</code><code class="re-group">)</code>&quot;')</code>
                    
144    </td>
                    
                
FeatureRuntimeModule.java git://github.com/bmwcarit/Jnario.git | Java | 365 lines
                    
12
                    
13import org.eclipse.xtend.core.compiler.UnicodeAwarePostProcessor;
                    
14import org.eclipse.xtend.core.compiler.XtendGenerator;
                    
14import org.eclipse.xtend.core.compiler.XtendGenerator;
                    
15import org.eclipse.xtend.core.compiler.XtendOutputConfigurationProvider;
                    
16import org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler;
                    
90import org.jnario.documentation.XtendDocumentationProvider;
                    
91import org.jnario.feature.compiler.FeatureBatchCompiler;
                    
92import org.jnario.feature.conversion.FeatureValueConverterService;
                    
                
warnings.py git://github.com/JetBrains/intellij-community.git | Python | 267 lines
                    
161           "lineno must be an int >= 0"
                    
162    item = (action, re.compile(message, re.I), category,
                    
163            re.compile(module), lineno)
                    
                
inheritance_diagram.py git://github.com/IronLanguages/main.git | Python | 366 lines
                    
54
                    
55class_sig_re = re.compile(r'''^([\w.]*\.)?    # module names
                    
56                          (\w+)  \s* $        # class/final module name
                    
                
runner.py git://github.com/nriley/jython.git | Python | 204 lines
                    
63                self.table_stack = []
                    
64                self.re_var = re.compile(r"\${(.*?)}")
                    
65
                    
                
PngImagePluginUpToDate.py git://pkgs.fedoraproject.org/gourmet | Python | 541 lines
                    
44
                    
45is_cid = re.compile("\w\w\w\w").match
                    
46
                    
                
irc.py git://github.com/coleifer/irc.git | Python | 359 lines
                    
22    # a couple handy regexes for reading text
                    
23    nick_re = re.compile('.*?Nickname is already in use')
                    
24    nick_change_re = re.compile(':(?P<old_nick>.*?)!\S+\s+?NICK\s+:\s*(?P<new_nick>[-\w]+)')
                    
24    nick_change_re = re.compile(':(?P<old_nick>.*?)!\S+\s+?NICK\s+:\s*(?P<new_nick>[-\w]+)')
                    
25    ping_re = re.compile('^PING (?P<payload>.*)')
                    
26    chanmsg_re = re.compile(':(?P<nick>.*?)!\S+\s+?PRIVMSG\s+(?P<channel>#+[-\w]+)\s+:(?P<message>[^\n\r]+)')
                    
26    chanmsg_re = re.compile(':(?P<nick>.*?)!\S+\s+?PRIVMSG\s+(?P<channel>#+[-\w]+)\s+:(?P<message>[^\n\r]+)')
                    
27    privmsg_re = re.compile(':(?P<nick>.*?)!~\S+\s+?PRIVMSG\s+[^#][^:]+:(?P<message>[^\n\r]+)')
                    
28    part_re = re.compile(':(?P<nick>.*?)!\S+\s+?PART\s+(?P<channel>#+[-\w]+)')
                    
28    part_re = re.compile(':(?P<nick>.*?)!\S+\s+?PART\s+(?P<channel>#+[-\w]+)')
                    
29    join_re = re.compile(':(?P<nick>.*?)!\S+\s+?JOIN\s+.*?(?P<channel>#+[-\w]+)')
                    
30    quit_re = re.compile(':(?P<nick>.*?)!\S+\s+?QUIT\s+.*')
                    
30    quit_re = re.compile(':(?P<nick>.*?)!\S+\s+?QUIT\s+.*')
                    
31    registered_re = re.compile(':(?P<server>.*?)\s+(?:376|422)')
                    
32
                    
                
test_fileinput.py git://github.com/IronLanguages/main.git | Python | 335 lines
                    
80    def buffer_size_test(self, t1, t2, t3, t4, bs=0, round=0):
                    
81        pat = re.compile(r'LINE (\d+) OF FILE (\d+)')
                    
82
                    
                
GroovyCompilerTests.java http://groovy-eclipse.googlecode.com/svn/trunk/ | Java | 228 lines
                    
1package org.codehaus.groovy.eclipse.core.compiler;
                    
2
                    
                
test_inference.py git://github.com/wesm/pandas.git | Python | 848 lines
                    
135def test_is_re():
                    
136    passes = re.compile('ad'),
                    
137    fails = 'x', 2, 3, object()
                    
146def test_is_recompilable():
                    
147    passes = (r'a', u('x'), r'asdf', re.compile('adsf'), u(r'\u2233\s*'),
                    
148              re.compile(r''))
                    
                
test_replace.py git://github.com/wesm/pandas.git | Python | 1115 lines
                    
73        # everything with compiled regexs as well
                    
74        res = dfobj.replace(re.compile(r'\s*\.\s*'), np.nan, regex=True)
                    
75        assert_frame_equal(dfobj, res.fillna('.'))
                    
77        # mixed
                    
78        res = dfmix.replace(re.compile(r'\s*\.\s*'), np.nan, regex=True)
                    
79        assert_frame_equal(dfmix, res.fillna('.'))
                    
82        # obj frame
                    
83        res = dfobj.replace(re.compile(r'\s*(\.)\s*'), r'\1\1\1')
                    
84        objc = obj.copy()
                    
89        # with mixed
                    
90        res = dfmix.replace(re.compile(r'\s*(\.)\s*'), r'\1\1\1')
                    
91        mixc = mix.copy()
                    
95
                    
96        res = dfmix.replace(regex=re.compile(r'\s*(\.)\s*'), value=r'\1\1\1')
                    
97        mixc = mix.copy()
                    
                
test_take.py git://github.com/wesm/pandas.git | Python | 468 lines
                    
70    # Standard incompatible fill error.
                    
71    fill_error = re.compile("Incompatible type for fill_value")
                    
72
                    
                
test_base.py git://github.com/wesm/pandas.git | Python | 1351 lines
                    
51class CheckImmutable(object):
                    
52    mutable_regex = re.compile('does not support mutable operations')
                    
53
                    
                
distro.py git://github.com/pypa/pip.git | Python | 1041 lines
                    
77# Pattern for content of distro release file (reversed)
                    
78_DISTRO_RELEASE_CONTENT_REVERSED_PATTERN = re.compile(
                    
79    r'(?:[^)]*\)(.*)\()? *(?:STL )?([\d.+\-a-z]*\d) *(?:esaeler *)?(.+)')
                    
81# Pattern for base file name of distro release file
                    
82_DISTRO_RELEASE_BASENAME_PATTERN = re.compile(
                    
83    r'(\w+)[-_](release|version)')
                    
                
test_base.py git://github.com/jezdez/django_compressor.git | Python | 456 lines
                    
173    def test_css_mtimes(self):
                    
174        is_date = re.compile(r'^\d{10}[\.\d]+$')
                    
175        for date in self.css_node.mtimes:
                    
183    def test_cachekey(self):
                    
184        is_cachekey = re.compile(r'\w{12}')
                    
185        self.assertTrue(is_cachekey.match(self.css_node.cachekey),
                    
                
options.py git://github.com/Yelp/mrjob.git | Python | 1638 lines
                    
67# use to identify malformed JSON
                    
68_PROBABLY_JSON_RE = re.compile(r'^\s*[\{\[\"].*$')
                    
69
                    
                
test_ext.py git://github.com/mitsuhiko/jinja2.git | Python | 640 lines
                    
16
                    
17_gettext_re = re.compile(r"_\((.*?)\)", re.DOTALL)
                    
18
                    
                
options.py git://github.com/rg3/youtube-dl.git | Python | 916 lines
                    
24    PRIVATE_OPTS = set(['-p', '--password', '-u', '--username', '--video-password', '--ap-password', '--ap-username'])
                    
25    eqre = re.compile('^(?P<key>' + ('|'.join(re.escape(po) for po in PRIVATE_OPTS)) + ')=.+$')
                    
26
                    
                
utils.py git://github.com/rg3/youtube-dl.git | Python | 5700 lines
                    
84# This is not clearly defined otherwise
                    
85compiled_regex_type = type(re.compile(''))
                    
86
                    
                
_tokenize_py3.py git://github.com/ipython/ipython.git | Python | 596 lines
                    
49from io import TextIOWrapper
                    
50cookie_re = re.compile("coding[:=]\s*([-\w.]+)")
                    
51
                    
137def _compile(expr):
                    
138    return re.compile(expr, re.UNICODE)
                    
139
                    
                
code.py git://github.com/ipython/ipython.git | Python | 730 lines
                    
44
                    
45ipython_input_pat = re.compile(r"<ipython\-input\-(\d+)-[a-z\d]+>$")
                    
46
                    
47# To match, e.g. 8-10 1:5 :10 3-
                    
48range_re = re.compile(r"""
                    
49(?P<start>\d+)?
                    
140    """
                    
141    indent_re = re.compile(r'\s+')
                    
142
                    
                
osm.py git://github.com/ipython/ipython.git | Python | 849 lines
                    
51            
                    
52            self.execre = re.compile(r'(.*)\.(%s)$' % winext,re.IGNORECASE)
                    
53
                    
                
lexers.py git://github.com/ipython/ipython.git | Python | 532 lines
                    
49
                    
50line_re = re.compile('.*?\n')
                    
51
                    
264    #: The regex to determine when a traceback starts.
                    
265    ipytb_start = re.compile(r'^(\^C)?(-+\n)|^(  File)(.*)(, line )(\d+\n)')
                    
266
                    
315        for attr in attrs:
                    
316            self.__setattr__(attr, re.compile(locals()[attr]))
                    
317
                    
                
ipython_directive.py git://github.com/ipython/ipython.git | Python | 1251 lines
                    
84    The compiled regular expression to denote the start of IPython input
                    
85    lines. The default is ``re.compile('In \\[(\\d+)\\]:\\s?(.*)\\s*')``. You
                    
86    shouldn't need to change this.
                    
92    The compiled regular expression to denote the start of IPython output
                    
93    lines. The default is ``re.compile('Out\\[(\\d+)\\]:\\s?(.*)\\s*')``. You
                    
94    shouldn't need to change this.
                    
                
utils.py git://github.com/liftoff/GateOne.git | Python | 1681 lines
                    
45OPENBSD = os.uname()[0] == 'OpenBSD'
                    
46CSS_END = re.compile('\.css.*?$')
                    
47JS_END = re.compile('\.js.*?$')
                    
                
configuration.py git://github.com/liftoff/GateOne.git | Python | 1394 lines
                    
30logger = go_logger(None)
                    
31comments_re = re.compile(
                    
32    r'//.*?$|/\*.*?\*/|\'(?:\\.|[^\\\'])*\'|"(?:\\.|[^\\"])*"',
                    
34)
                    
35trailing_commas_re = re.compile(
                    
36    r'(,)\s*}(?=([^"\\]*(\\.|"([^"\\]*\\.)*[^"\\]*"))*[^"]*$)')
                    
                
resolvers.py git://github.com/django/django.git | Python | 685 lines
                    
188        try:
                    
189            return re.compile(regex)
                    
190        except re.error as e:
                    
283    def _compile(self, route):
                    
284        return re.compile(_route_to_regex(route, self._is_endpoint)[0])
                    
285
                    
297        # This is only used by reverse() and cached in _reverse_dict.
                    
298        return re.compile(self.language_prefix)
                    
299
                    
                
test_extraction.py git://github.com/django/django.git | Python | 785 lines
                    
79        needle = ''.join(parts)
                    
80        pattern = re.compile(r'^\#\:.*' + re.escape(needle), re.MULTILINE)
                    
81        if assert_presence:
                    
                
capp_lint git://github.com/cappuccino/cappuccino.git | Python | 1167 lines
                    
128
                    
129    VAR_BLOCK_START_RE = re.compile(ur'''(?x)
                    
130        (?P<indent>\s*)         # indent before a var keyword
                    
140
                    
141    SEPARATOR_RE = re.compile(ur'''(?x)
                    
142        (?P<expression>.*)              # Everything up to the line separator
                    
170
                    
171    STATEMENT_RE = re.compile(ur'''(?x)
                    
172        \s*((continue|do|for|function|if|else|return|switch|while|with)\b|\[+\s*[a-zA-Z_$]\w*\s+[a-zA-Z_$]\w*\s*[:\]])
                    
174
                    
175    TRAILING_WHITESPACE_RE = re.compile(ur'^.*(\s+)$')
                    
176    STRIP_LINE_COMMENT_RE = re.compile(ur'(.*)\s*(?://.*|/\*.*\*/\s*)$')
                    
176    STRIP_LINE_COMMENT_RE = re.compile(ur'(.*)\s*(?://.*|/\*.*\*/\s*)$')
                    
177    LINE_COMMENT_RE = re.compile(ur'\s*(?:/\*.*\*/\s*|//.*)$')
                    
178    COMMENT_RE = re.compile(ur'/\*.*?\*/')
                    
                
jsduck_generator.py git://github.com/appcelerator/titanium_mobile.git | Python | 639 lines
                    
32# compiling REs ahead of time, since we use them heavily.
                    
33link_parts_re = re.compile(r"(?:\[([^\]]+?)\]\(([^\)\s]+?)\)|\<([^\s]+)\>)", re.MULTILINE)
                    
34# To add Alloy tags in the description, use backticks around the tag (`<Button>`, e.g.).
                    
34# To add Alloy tags in the description, use backticks around the tag (`<Button>`, e.g.).
                    
35find_links_re = re.compile(r"(\[[^\]]+?\]\([^\)\s]+?\)|(?!`)\<[^\s]+\>(?!`))", re.MULTILINE)
                    
36html_scheme_re = re.compile(r"^http:|^https:")
                    
36html_scheme_re = re.compile(r"^http:|^https:")
                    
37doc_site_url_re = re.compile(r"http://docs.appcelerator.com/titanium/.*(#!.*)")
                    
38# we use this to distinguish inline HTML tags from Markdown links. Not foolproof, and a
                    
39# we should probably find a better technique in the long run.
                    
40html_element_re = re.compile("([a-z]|\/)")
                    
41
                    
                
 

Source

Language