Are there ways to mitigate the cons of dynamic typing?