commit | 87973b3b5dbe2d42d2def3419c76fbc09486e8f4 | [log] [tgz] |
---|---|---|
author | Louis Dionne <ldionne@apple.com> | Wed Sep 04 12:48:32 2019 +0000 |
committer | Max Spector <mspector@google.com> | Wed Sep 18 18:14:07 2019 -0700 |
tree | 88661ddead7a57426f4079224908afddcd67b41d | |
parent | 13717bb9604ae58240b1d2c1f139f8911b5f4111 [diff] |
DO NOT MERGE: [libc++] Add `__truncating_cast` for safely casting float types to integers This is needed anytime we need to clamp an arbitrary floating point value to an integer type. Thanks to Eric Fiselier for the patch. Differential Revision: https://reviews.llvm.org/D66836 git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@370891 91177308-0d34-0410-b5e6-96231b3b80d8 (cherry picked from commit c9ac8d533010d8915bcfdecab891fb451f71ce74) (cherry picked from commit 4561f55204960c0b3bc4594089ddcf56e5655cad) Bug: https://bugs.chromium.org/p/chromium/issues/detail?id=994957 Bug: http://b/139690488 Change-Id: Icc81b5f68f0f87b74ccd4eba5971fd1e14ef13a5 (cherry picked from commit 66ddc699d1ffc37f4ced50af186b480dbc88d44e)