From: Timm Bäder Date: Fri, 14 Oct 2022 09:44:23 +0000 (+0200) Subject: [clang][Interp][NFC] Explain why tests are disabled X-Git-Tag: upstream/17.0.6~30585 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b3d495e7e082c3a3c77bfcf2ed928f6f18f69fc4;p=platform%2Fupstream%2Fllvm.git [clang][Interp][NFC] Explain why tests are disabled Disabled to make the buildbots happy in c004d7534dcefcfebc3e07a7fa12f5492be80279. In C++14, the functions here use a MaterializeTemporaryExpr, which the new constant interpreter doesn't support yet. Add comments for this and two new RUN lines. --- diff --git a/clang/test/AST/Interp/records.cpp b/clang/test/AST/Interp/records.cpp index 8b2c92c..002ea19 100644 --- a/clang/test/AST/Interp/records.cpp +++ b/clang/test/AST/Interp/records.cpp @@ -1,6 +1,8 @@ // RUN: %clang_cc1 -fexperimental-new-constant-interpreter -verify %s +// RUN: %clang_cc1 -fexperimental-new-constant-interpreter -std=c++14 -verify %s // RUN: %clang_cc1 -fexperimental-new-constant-interpreter -triple i686 -verify %s // RUN: %clang_cc1 -verify=ref %s +// RUN: %clang_cc1 -verify=ref -std=c++14 %s // RUN: %clang_cc1 -verify=ref -triple i686 %s // expected-no-diagnostics @@ -50,7 +52,9 @@ static_assert(ints2.a == -20, ""); static_assert(ints2.b == -30, ""); static_assert(!ints2.c, ""); -#if 0 +#if __cplusplus >= 201703L +// FIXME: In c++14, this uses a MaterializeTemporaryExpr, +// which the new interpreter doesn't support yet. constexpr Ints getInts() { return {64, 128, true}; } @@ -122,7 +126,9 @@ constexpr const C* getPointer() { } static_assert(getPointer()->a == 100, ""); -#if 0 +#if __cplusplus >= 201703L +// FIXME: In c++14, this uses a MaterializeTemporaryExpr, +// which the new interpreter doesn't support yet. constexpr C RVOAndParams(const C *c) { return C(); }