Reg ex error for in/excludeiripattern (formal doc)

Working through the implementation feature list I've detected an error 
in one of the regexes (annoying since I could have sworn I've tested all 
those to destruction already. Ah well, you can never test things too much).

Just above example 4-3 in the Formal Doc [1] the asterisk just before $1 
in this line:

Else if h matches the regular expression ^\*\.(.*) then let h be 
([^\:\/\?\#\@]+\.)*$1 where $1 refers to ^\*\.(.*)

Should be a +.

This is because the IRI pattern *.example.com is meant to match all 
subdomains of example.com but not example.com itself. In other words you 
must have at least one ([^\:\/\?\#\@]+\.) before the .example.com - 
which is what + does (* matches even if there's no subdomain).

Phil.

[1] http://www.w3.org/TR/2008/WD-powder-formal-20081114/#eg4-3


-- 
Phil Archer
w. http://philarcher.org/

Received on Thursday, 18 December 2008 11:48:43 UTC