xquery based on reference

for example:

$m/@spouse=>person/name

does quip2.2.1 support that?

I have tried that too and am looking for the answer to this. It does not seem to be working and neither is IDREF!