[llvm] r373820 - [UnitTests] Try and pacify gcc-5
James Molloy via llvm-commits
llvm-commits at lists.llvm.org
Sat Oct 5 01:57:18 PDT 2019
Author: jamesm
Date: Sat Oct 5 01:57:17 2019
New Revision: 373820
URL: http://llvm.org/viewvc/llvm-project?rev=373820&view=rev
Log:
[UnitTests] Try and pacify gcc-5
This looks like a defect in gcc-5 where it chooses a constexpr
constructor from the initializer-list that it considers to be explicit.
I've tried to reproduce but I can't install anything prior to gcc-6 easily
on my system, and that doesn't have the error. So this is speculative
pacification.
Reported by Steven Wan.
Modified:
llvm/trunk/unittests/TableGen/AutomataTest.cpp
Modified: llvm/trunk/unittests/TableGen/AutomataTest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/TableGen/AutomataTest.cpp?rev=373820&r1=373819&r2=373820&view=diff
==============================================================================
--- llvm/trunk/unittests/TableGen/AutomataTest.cpp (original)
+++ llvm/trunk/unittests/TableGen/AutomataTest.cpp Sat Oct 5 01:57:17 2019
@@ -62,16 +62,16 @@ TEST(Automata, TupleAutomatonAccepts) {
Automaton<TupleAutomatonAction> A(makeArrayRef(TupleAutomatonTransitions));
A.reset();
EXPECT_TRUE(
- A.add({SK_a, SK_b, "yeet"}));
+ A.add(TupleAutomatonAction{SK_a, SK_b, "yeet"}));
A.reset();
EXPECT_FALSE(
- A.add({SK_a, SK_a, "yeet"}));
+ A.add(TupleAutomatonAction{SK_a, SK_a, "yeet"}));
A.reset();
EXPECT_FALSE(
- A.add({SK_a, SK_b, "feet"}));
+ A.add(TupleAutomatonAction{SK_a, SK_b, "feet"}));
A.reset();
EXPECT_TRUE(
- A.add({SK_b, SK_b, "foo"}));
+ A.add(TupleAutomatonAction{SK_b, SK_b, "foo"}));
}
TEST(Automata, NfaAutomatonAccepts) {
More information about the llvm-commits
mailing list