[SPARK-4108][SQL] Fixed usage of deprecated in sql/catalyst/types/datatypes

Fixed usage of deprecated in sql/catalyst/types/datatypes to have versio...n parameter