[REG2.066a] Issue 13284 - Cannot match shared classes at receive

https://issues.dlang.org/show_bug.cgi?id=13284

Support getting `shared` object from `Variant`.