Revert "[llvm] Improve llvm.objectsize computation by computing GEP, alloca and mallo...
[llvm-project.git] / clang / test / SemaCXX / constexpr-unsigned-high-bit.cpp
blobd85e645509d8e9ede330e7cdeaadc06cf737d2db
1 // RUN: %clang_cc1 -std=c++14 -fsyntax-only %s
2 // RUN: %clang_cc1 -std=c++14 -fsyntax-only -fexperimental-new-constant-interpreter %s
4 #include <limits.h>
6 constexpr unsigned inc() {
7 unsigned i = INT_MAX;
8 ++i; // should not warn value is outside range
9 return i;
12 constexpr unsigned dec() {
13 unsigned i = INT_MIN;
14 --i; // should not warn value is outside range
15 return i;