Skip to content

Commit eade61f

Browse files
frederick-vs-jamahesh-attarde
authored andcommitted
[CodeGen][test] Fix Buildbot failure due to uninitialized variables (llvm#161085)
Under some options used by LLVM Buildbot, an uninitialized variable (recently added to the test suite) caused constant evaluation failure, despite the type of that variable is an empty class. This PR explicitly initializes the variables with `{}` to fix the error. Follows-up a558d65.
1 parent 94485e1 commit eade61f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/unittests/CodeGen/TypeTraitsTest.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ static_assert(std::is_trivially_copyable_v<IdentifyingPassPtr>,
3939
template <class Fn> constexpr bool CheckStdCmpRequirements() {
4040
// std::less and std::equal_to are literal, default constructible, and
4141
// copyable classes.
42-
Fn f1;
42+
Fn f1{};
4343
auto f2 = f1;
4444
auto f3 = std::move(f2);
4545
f2 = f3;

0 commit comments

Comments
 (0)