Refactorization of Varaint (switched from std::type_index to plain index of type (uchar))