mirror of
https://codeberg.org/ziglang/zig.git
synced 2026-04-27 19:09:47 +03:00
std: Remove a handful of things deprecated during the 0.15 release cycle
- std.Build.Step.Compile.root_module mutators -> std.Build.Module - std.Build.Step.Compile.want_lto -> std.Build.Step.Compile.lto - std.Build.Step.ConfigHeader.getOutput -> std.Build.Step.ConfigHeader.getOutputFile - std.Build.Step.Run.max_stdio_size -> std.Build.Step.Run.stdio_limit - std.enums.nameCast -> @field(E, tag_name) / @field(E, @tagName(tag)) - std.Io.tty.detectConfig -> std.Io.tty.Config.detect - std.mem.trimLeft -> std.mem.trimStart - std.mem.trimRight -> std.mem.trimEnd - std.meta.intToEnum -> std.enums.fromInt - std.meta.TagPayload -> @FieldType(U, @tagName(tag)) - std.meta.TagPayloadByName -> @FieldType(U, tag_name)
This commit is contained in:
@@ -1221,9 +1221,6 @@ test trimStart {
|
||||
try testing.expectEqualSlices(u8, "foo\n ", trimStart(u8, " foo\n ", " \n"));
|
||||
}
|
||||
|
||||
/// Deprecated: use `trimStart` instead.
|
||||
pub const trimLeft = trimStart;
|
||||
|
||||
/// Remove a set of values from the end of a slice.
|
||||
pub fn trimEnd(comptime T: type, slice: []const T, values_to_strip: []const T) []const T {
|
||||
var end: usize = slice.len;
|
||||
@@ -1235,9 +1232,6 @@ test trimEnd {
|
||||
try testing.expectEqualSlices(u8, " foo", trimEnd(u8, " foo\n ", " \n"));
|
||||
}
|
||||
|
||||
/// Deprecated: use `trimEnd` instead.
|
||||
pub const trimRight = trimEnd;
|
||||
|
||||
/// Remove a set of values from the beginning and end of a slice.
|
||||
pub fn trim(comptime T: type, slice: []const T, values_to_strip: []const T) []const T {
|
||||
var begin: usize = 0;
|
||||
|
||||
Reference in New Issue
Block a user