bugfix for PrimitiveType visit