1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-02-15 18:55:46 +01:00

Add named groups (a la Python) to util.regexp.

This commit is contained in:
Kris Maglione
2011-01-12 12:25:46 -05:00
parent d6e22872d3
commit c3a90cf2b3
10 changed files with 68 additions and 51 deletions

View File

@@ -212,11 +212,11 @@ var Highlights = Module("Highlight", {
sheetRegexp: util.regexp(<![CDATA[
^\s*
!? \*?
( (?:[^;\s]|\s[^;\s])+ )
(?:; ( (?:[^;\s]|\s[^;\s])+ )? )?
(?:; ( (?:[^;\s]|\s[^;\s])+ )? )?
(?:; ( (?:[^;\s]|\s[^;\s])+ )? )?
\s* (.*)
(?P<group> (?:[^;\s]|\s[^;\s])+ )
(?:; (?P<selector> (?:[^;\s]|\s[^;\s])+ )? )?
(?:; (?P<sites> (?:[^;\s]|\s[^;\s])+ )? )?
(?:; (?P<extends> (?:[^;\s]|\s[^;\s])+ )? )?
\s* (?P<css> .*)
$
]]>),