Merge remote-tracking branch 'origin/main' into rebranch

This commit is contained in:
swift-ci
2024-06-05 14:36:10 -07:00
7 changed files with 38 additions and 23 deletions

View File

@@ -335,6 +335,12 @@ static ValidationInfo validateControlBlock(
LLVM_FALLTHROUGH;
case 3:
result.shortVersion = blobData.slice(0, scratch[2]);
// If the format version doesn't match, give up after also getting the
// compiler version. This provides better diagnostics.
if (result.status != Status::Valid)
return result;
LLVM_FALLTHROUGH;
case 2:
case 1: