microsoft / GSL

Guidelines Support Library
Other
6.13k stars 737 forks source link

gsl::narrow and NaN #1069

Closed andrewkcorcoran closed 1 year ago

andrewkcorcoran commented 1 year ago

Currently NaN values always cause gsl::narrow to throw (even when the cast is a no-op). This could be seen as non-intuitive to the user so we should probably explicitly document this in the header comments.