[compiler-rt] r363805 - [libFuzzer] Remove too aggressive static_assert in FuzzedDataProvider.
Max Moroz via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 19 07:14:27 PDT 2019
Author: dor1s
Date: Wed Jun 19 07:14:27 2019
New Revision: 363805
URL: http://llvm.org/viewvc/llvm-project?rev=363805&view=rev
Log:
[libFuzzer] Remove too aggressive static_assert in FuzzedDataProvider.
Summary:
http://lab.llvm.org:8011/builders/clang-cmake-aarch64-full/builds/31
error: static_assert failed due to requirement
'std::numeric_limits<char>::is_signed' "Destination type must be
signed."
static_assert(std::numeric_limits<TS>::is_signed,
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/buildslave/buildslave/clang-cmake-aarch64-full/llvm/projects/compiler-rt/lib/fuzzer/utils/FuzzedDataProvider.h:126:19:
note: in instantiation of function template specialization
'FuzzedDataProvider::ConvertUnsignedToSigned<char, unsigned char>'
requested here
char next = ConvertUnsignedToSigned<char>(data_ptr_[0]);
^
1 error generated.
Reviewers: Dor1s
Reviewed By: Dor1s
Subscribers: javed.absar, kristof.beyls, delcypher, #sanitizers, llvm-commits
Tags: #llvm, #sanitizers
Differential Revision: https://reviews.llvm.org/D63553
Modified:
compiler-rt/trunk/lib/fuzzer/utils/FuzzedDataProvider.h
Modified: compiler-rt/trunk/lib/fuzzer/utils/FuzzedDataProvider.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/fuzzer/utils/FuzzedDataProvider.h?rev=363805&r1=363804&r2=363805&view=diff
==============================================================================
--- compiler-rt/trunk/lib/fuzzer/utils/FuzzedDataProvider.h (original)
+++ compiler-rt/trunk/lib/fuzzer/utils/FuzzedDataProvider.h Wed Jun 19 07:14:27 2019
@@ -223,8 +223,6 @@ private:
static_assert(sizeof(TS) == sizeof(TU), "Incompatible data types.");
static_assert(!std::numeric_limits<TU>::is_signed,
"Source type must be unsigned.");
- static_assert(std::numeric_limits<TS>::is_signed,
- "Destination type must be signed.");
// TODO(Dor1s): change to `if constexpr` once C++17 becomes mainstream.
if (std::numeric_limits<TS>::is_modulo)
More information about the llvm-commits
mailing list