Text = 123-45-6789

The object is to make sure that the separator (or lack of) between 45 and 6789 is the same as between 123 and 45

Regex's
\d{3}(?<xxx>[ -]?)\d{2}\k<xxx>\d{4} and \d{3}(?'xxx'[ -]?)\d{2}\k'xxx'\d{4}
both fail, but

\d{3}([ -]?)\d{2}\1\d{4} works just fine

Eliminating the \k<xxx> doesn't help. The rejection seems to be triggered by the appearance of (?

I cannot get a match in Qt, on any web regex validator, or anywhere else. Does anyone know what's wrong with this simple regex/text combination?