Confirmed users, Bureaucrats and Sysops emeriti
419
edits
Line 37: | Line 37: | ||
=== Functions === | === Functions === | ||
Let origin(s) = (s matches | (String matches operator takes either a string right operand to prefix-match, or a `-quoted pattern, informally connoting a pattern to match. The result of matches is either the empty string, which converts to false, or the matching prefix string.) | ||
Let origin(s) = (s matches `scheme://hostpart`) || unknown. | |||
Let pseudo(s) = (!s || s matches 'about:' || s matches 'data:' || s matches('javascript:'). | Let pseudo(s) = (!s || s matches 'about:' || s matches 'data:' || s matches('javascript:'). |