Fix enum->int unbox casts in gsharedvt code. Fixes desk #42463.