I completly agree with you !
B
bNobo34
@bNobo34
Posts
-
c# Casting v As operator -
c# Casting v As operator"Because it's better" - InvalidArgumentException :)
-
c# Casting v As operatorPotential "invisible" bugs hard to debug if you forget to test "null value" after using AS operator. Personnaly, I prefer to have an exception, even if it's a little bit more code to handle it. If I forget the error handler, there is an immediate punishment :)