Hi Evolution, I was wondering if we would consider adding a percentage type to Swift. This would be a type with a value between 0 & 1.
I know we can and do use doubles or floats for this now, but there really is a semantic difference between most parameters that take a value between 0 & 1 and those that take any floating point value. It would be nice to have a type that semantically means that the value is from 0 to 1. It could even just wrap a Double for speed (in my own code I wrap a UInt64 for decimal accuracy… and to avoid issues around comparisons). Thanks, Jon _______________________________________________ swift-evolution mailing list email@example.com https://lists.swift.org/mailman/listinfo/swift-evolution