Skip to content

Commit 69f581a

Browse files
author
joaosaffran
committed
making code clearer
1 parent 74f7226 commit 69f581a

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

llvm/include/llvm/BinaryFormat/DXContainer.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -557,10 +557,11 @@ struct RootSignatureValidations {
557557
}
558558

559559
static Expected<uint32_t> validateVersion(uint32_t Version) {
560-
if (Version < 1 || Version > 2)
561-
return llvm::make_error<BinaryStreamError>(
562-
"Invalid Root Signature Version");
563-
return Version;
560+
if (Version == 1 || Version == 2)
561+
return Version;
562+
563+
return llvm::make_error<BinaryStreamError>(
564+
"Invalid Root Signature Version");
564565
}
565566
};
566567

0 commit comments

Comments
 (0)