The Attribute Equals Selector doc says that the attribute value "Can be either an unquoted single word or a quoted string."
This is a bit vague in light of jquery/jquery#2824, as #anchor needs to be quoted. Perhaps we should just say that the value must be quoted, as describing how #anchor is a special case and not a single word seems a bit complex.