Detect set type based on first element added