Add comment to SkTPin explaining NaN behavior

Change-Id: Ifaf86ce24dcc8843172761f4e210b0df6f83d32d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270062
Reviewed-by: Mike Reed <reed@google.com>
diff --git a/include/core/SkTypes.h b/include/core/SkTypes.h
index c32655e..93eda2a 100644
--- a/include/core/SkTypes.h
+++ b/include/core/SkTypes.h
@@ -585,6 +585,9 @@
 }
 
 /** @return value pinned (clamped) between min and max, inclusively.
+
+    NOTE: Unlike std::clamp, SkTPin has well-defined behavior if 'value' is a
+          floating point NaN. In that case, 'max' is returned.
 */
 template <typename T> static constexpr const T& SkTPin(const T& value, const T& min, const T& max) {
     return value < min ? min : (value < max ? value : max);