handle not only strings in date type cast
fix subclass override not renamed with e2d19d60.