[mypyc] Fix name lookup when class var and module var have the same name (#21594)
Disambiguate using the Var node, since the short name itself is not
enough to disambiguate between global variable and class variable
with the same name.
Fixes https://github.com/mypyc/mypyc/issues/1201.