reword deprecated error slightly

"found" -> "reached" to match "reached unreachable code"
This commit is contained in:
Andrew Kelley 2025-02-25 23:59:48 -08:00
parent c5aa680c88
commit f74a856d84
3 changed files with 3 additions and 3 deletions

View File

@ -1409,7 +1409,7 @@ fn analyzeBodyInner(
if (!mod.allow_deprecated) {
const src_node: i32 = @bitCast(extended.operand);
const src = block.nodeOffset(src_node);
return sema.fail(block, src, "found deprecated code", .{});
return sema.fail(block, src, "reached deprecated code", .{});
}
i += 1;

View File

@ -6,4 +6,4 @@ pub export fn foo() usize {
// error
//
// :1:13: error: found deprecated code
// :1:13: error: reached deprecated code

View File

@ -1180,7 +1180,7 @@ pub fn addCliTests(b: *std.Build) *Step {
// Test `zig build -fallow-deprecated`.
const deprecated_check: std.Build.Step.Run.StdIo.Check = .{
.expect_stderr_match = "found deprecated code",
.expect_stderr_match = "reached deprecated code",
};
const tmp_path = b.makeTempPath();