fix reportInvalidCast
false positive when casting to/from None
and type
#579
+20
−11
reportInvalidCast
false positive when casting to/from None
and type
#579