add contains variant returning existing value (if any)
more efficient hash lookup