diff --git a/deps.zig b/deps.zig index acfc4f0..ecdb9af 100644 --- a/deps.zig +++ b/deps.zig @@ -57,7 +57,6 @@ pub fn fetch(exe: *std.build.LibExeObjStep) void { } exe.step.dependOn(&GitExactStep.create(b, "https://github.com/nektro/zig-extras", "05f0e90a185cb04a09b96f686dffc6375c420e9b").step); exe.step.dependOn(&GitExactStep.create(b, "https://github.com/nektro/zig-flag", "3d3596ec79017afc6bd5d2f3a902bd2a10a904e4").step); - exe.step.dependOn(&GitExactStep.create(b, "https://github.com/nektro/zig-range", "4b2f12808aa09be4b27a163efc424dd4e0415992").step); } fn trimPrefix(comptime T: type, haystack: []const T, needle: []const T) []const T { @@ -166,22 +165,15 @@ pub const package_data = struct { .entry = "/git/github.com/nektro/zig-flag/3d3596ec79017afc6bd5d2f3a902bd2a10a904e4/src/lib.zig", .deps = &[_]*Package{ &_f7dubzb7cyqe }, }; - pub var _tnj3qf44tpeq = Package{ - .store = "/git/github.com/nektro/zig-range/4b2f12808aa09be4b27a163efc424dd4e0415992", - .name = "range", - .entry = "/git/github.com/nektro/zig-range/4b2f12808aa09be4b27a163efc424dd4e0415992/src/lib.zig", - }; pub var _root = Package{ }; }; pub const packages = [_]*Package{ - &package_data._tnj3qf44tpeq, &package_data._pm68dn67ppvl, }; pub const pkgs = struct { - pub const range = &package_data._tnj3qf44tpeq; pub const flag = &package_data._pm68dn67ppvl; }; diff --git a/src/main.zig b/src/main.zig index 36c551c..8079e55 100644 --- a/src/main.zig +++ b/src/main.zig @@ -1,6 +1,5 @@ const std = @import("std"); const string = []const u8; -const range = @import("range").range; const flag = @import("flag"); const linters = [_]*const fn (std.mem.Allocator, []const u8, *Source, std.fs.File.Writer) WorkError!void{ @@ -131,7 +130,7 @@ pub const Loc = struct { pub fn locToLoc(source: [:0]const u8, loc: std.zig.Token.Loc) Loc { var line: usize = 1; var pos: usize = 1; - for (range(loc.start), 0..) |_, i| { + for (0..loc.start) |i| { pos += 1; if (source[i] != '\n') continue; line += 1; diff --git a/zig.mod b/zig.mod index 11c6fc5..cc55a87 100644 --- a/zig.mod +++ b/zig.mod @@ -6,5 +6,4 @@ min_zig_version: 0.11.0 bin: True provides: ["ziglint"] root_dependencies: - - src: git https://github.com/nektro/zig-range - src: git https://github.com/nektro/zig-flag diff --git a/zigmod.lock b/zigmod.lock index f31a294..88054f7 100644 --- a/zigmod.lock +++ b/zigmod.lock @@ -1,4 +1,3 @@ 2 git https://github.com/nektro/zig-extras commit-05f0e90a185cb04a09b96f686dffc6375c420e9b git https://github.com/nektro/zig-flag commit-3d3596ec79017afc6bd5d2f3a902bd2a10a904e4 -git https://github.com/nektro/zig-range commit-4b2f12808aa09be4b27a163efc424dd4e0415992