Skip to content

Commit f700d74

Browse files
[libc] fix more -Wmissing-brace (#77382)
Similar to #77345, the buildbots are observing similar warnings for the sse2 implementation. llvm-project/libc/src/__support/HashTable/sse2/bitmask_impl.inc:36:13: error: suggest braces around initialization of subobject [-Werror,-Wmissing-braces] return {bitmask}; ^~~~~~~ { } llvm-project/libc/src/__support/HashTable/sse2/bitmask_impl.inc:45:13: error: suggest braces around initialization of subobject [-Werror,-Wmissing-braces] return {static_cast<uint16_t>(~mask_available().word)}; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ { } Link: https://lab.llvm.org/buildbot/#/builders/163/builds/49350/steps/8/logs/stdio Link: #74506
1 parent 16b8a0d commit f700d74

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libc/src/__support/HashTable/sse2/bitmask_impl.inc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ struct Group {
3333
LIBC_INLINE IteratableBitMask match_byte(uint8_t byte) const {
3434
auto cmp = _mm_cmpeq_epi8(data, _mm_set1_epi8(byte));
3535
auto bitmask = static_cast<uint16_t>(_mm_movemask_epi8(cmp));
36-
return {bitmask};
36+
return {{bitmask}};
3737
}
3838

3939
LIBC_INLINE BitMask mask_available() const {
@@ -42,7 +42,7 @@ struct Group {
4242
}
4343

4444
LIBC_INLINE IteratableBitMask occupied() const {
45-
return {static_cast<uint16_t>(~mask_available().word)};
45+
return {{static_cast<uint16_t>(~mask_available().word)}};
4646
}
4747
};
4848
} // namespace internal

0 commit comments

Comments
 (0)