authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2023-01-31 13:48:24-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2023-01-31 15:09:35-07:00
log13a96165405af33fa6ef43a3ce2c1d8aea846287
tree9c817a18375e41ac5ca7ad70c357825702fb7a16
parent16cdd1297ebfac534615eaeb8439a4e1de71837c

std.Build: add deprecated declarations

These declarations are now aliases of their new APIs and marked as deprecated via doc comments: * std.build.Builder * std.build * std.Build.LibExeObjStep

2 files changed, 8 insertions(+), 12 deletions(-)

lib/std/Build.zig+6-5
......@@ -19,8 +19,12 @@ const NativeTargetInfo = std.zig.system.NativeTargetInfo;
1919const Sha256 = std.crypto.hash.sha2.Sha256;
2020const Build = @This();
2121
22///// deprecated: use `CompileStep` instead.
23//pub const LibExeObjStep = CompileStep;
22/// deprecated: use `CompileStep`.
23pub const LibExeObjStep = CompileStep;
24/// deprecated: use `Build`.
25pub const Builder = Build;
26/// deprecated: use `InstallDirStep.Options`
27pub const InstallDirectoryOptions = InstallDirStep.Options;
2428
2529pub const Step = @import("Build/Step.zig");
2630pub const CheckFileStep = @import("Build/CheckFileStep.zig");
......@@ -1637,9 +1641,6 @@ pub fn constructCMacro(allocator: Allocator, name: []const u8, value: ?[]const u
16371641 return macro;
16381642}
16391643
1640/// deprecated: use `InstallDirStep.Options`
1641pub const InstallDirectoryOptions = InstallDirStep.Options;
1642
16431644pub const VcpkgRoot = union(VcpkgRootStatus) {
16441645 unattempted: void,
16451646 not_found: void,
lib/std/std.zig+2-7
......@@ -96,13 +96,8 @@ pub const wasm = @import("wasm.zig");
9696pub const zig = @import("zig.zig");
9797pub const start = @import("start.zig");
9898
99///// Deprecated. Use `std.Build` instead.
100///// TODO: remove this after releasing 0.11.0
101//pub const build = struct {
102// /// Deprecated. Use `std.Build` instead.
103// /// TODO: remove this after releasing 0.11.0
104// pub const Builder = Build;
105//};
99/// deprecated: use `Build`.
100pub const build = Build;
106101
107102const root = @import("root");
108103const options_override = if (@hasDecl(root, "std_options")) root.std_options else struct {};