Skip to content

Commit b64f69c

Browse files
Update llvm/include/llvm/Support/YAMLTraits.h
Co-authored-by: Nikita Popov <[email protected]>
1 parent 944bf0d commit b64f69c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/include/llvm/Support/YAMLTraits.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -904,7 +904,7 @@ class IO {
904904
void mapOptionalWithContext(const char *Key, T &Val, Context &Ctx) {
905905
if constexpr (has_SequenceTraits<T>::value) {
906906
// omit key/value instead of outputting empty sequence
907-
if (this->canElideEmptySequence() && !(Val.begin() != Val.end()))
907+
if (this->canElideEmptySequence() && Val.begin() == Val.end())
908908
return;
909909
}
910910
this->processKey(Key, Val, false, Ctx);

0 commit comments

Comments
 (0)