Fix gsharedvt support for gsharedvt methods on shared classes. Fixes #11933.