[clang-repl] Another try on system-z.
This patch should make msan happy as it found a real bug where we always try to read an unsigned long long without respecting the underlying enum type. Another follow-up on llvm/llvm-project#102858
This commit is contained in:
parent
0dfac65595
commit
6163b66e0a
@ -106,7 +106,7 @@ static std::string EnumToString(const Value &V) {
|
||||
assert(EnumTy && "Fail to cast to enum type");
|
||||
|
||||
EnumDecl *ED = EnumTy->getDecl();
|
||||
uint64_t Data = V.getULongLong();
|
||||
uint64_t Data = V.convertTo<uint64_t>();
|
||||
bool IsFirst = true;
|
||||
llvm::APSInt AP = Ctx.MakeIntValue(Data, DesugaredTy);
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
// RUN: clang-repl "int i = 10;" 'extern "C" int printf(const char*,...);' \
|
||||
// RUN: 'auto r1 = printf("i = %d\n", i);' | FileCheck --check-prefix=CHECK-DRIVER %s
|
||||
// UNSUPPORTED: system-aix, system-zos, asan
|
||||
// UNSUPPORTED: system-aix
|
||||
// CHECK-DRIVER: i = 10
|
||||
// RUN: cat %s | clang-repl -Xcc -std=c++11 -Xcc -fno-delayed-template-parsing | FileCheck %s
|
||||
extern "C" int printf(const char*,...);
|
||||
|
@ -392,9 +392,6 @@ TEST_F(InterpreterTest, Value) {
|
||||
EXPECT_EQ(V9.getKind(), Value::K_PtrOrObj);
|
||||
EXPECT_TRUE(V9.isManuallyAlloc());
|
||||
|
||||
if (llvm::Triple(llvm::sys::getDefaultTargetTriple()).isSystemZ())
|
||||
GTEST_SKIP(); // Enum printing is broken for unknown reasons on SystemZ.
|
||||
|
||||
Value V10;
|
||||
llvm::cantFail(Interp->ParseAndExecute(
|
||||
"enum D : unsigned int {Zero = 0, One}; One", &V10));
|
||||
|
Loading…
x
Reference in New Issue
Block a user