Revert "replace static_cast with typeAs"
Revert "replace static_cast with typeAs"

This reverts commit cd9e314ec4399e65e9a0422bc11ad5bdc6f051ca.

sekiguchi-nagisa/ydsh,sekiguchi-nagisa/ydsh,sekiguchi-nagisa/ydsh