OSDN Git Service

MathExtras: Parametrize count(Trailing|Leading)Zeros on the type size.
authorBenjamin Kramer <benny.kra@googlemail.com>
Thu, 12 Feb 2015 13:47:29 +0000 (13:47 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Thu, 12 Feb 2015 13:47:29 +0000 (13:47 +0000)
commit9df41118765391f5025c8278ddc2024505e47fa5
tree4ba3c6be22d71ead0e847fe73d6bc5ba6f2b9ae5
parentb0d513e1ebdf49230467047fb10e1cc5ad5f1ecc
MathExtras: Parametrize count(Trailing|Leading)Zeros on the type size.

Otherwise we will always select the generic version for e.g. unsigned
long if uint64_t is typedef'd to 'unsigned long long'. Also remove
enable_if hacks in favor of static_assert.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@228921 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Support/MathExtras.h