diff options
| author | r00ster91 <r00ster91@proton.me> | 2022-09-29 09:43:22 +0200 |
|---|---|---|
| committer | Luuk de Gram <luuk@degram.dev> | 2022-09-29 21:40:25 +0200 |
| commit | f6312e4b6933b8c8d163d6e6b20da135c5fa986a (patch) | |
| tree | b0d4b840557325af442ff0f68f33ffbc565dd13a /lib/std | |
| parent | fda0b2c372c3e9ecc348a9cc4afc4e7afd966427 (diff) | |
| download | zig-f6312e4b6933b8c8d163d6e6b20da135c5fa986a.tar.gz zig-f6312e4b6933b8c8d163d6e6b20da135c5fa986a.zip | |
docs: minor improvements
Just some minor improvements when passing by.
Diffstat (limited to 'lib/std')
| -rw-r--r-- | lib/std/testing.zig | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/std/testing.zig b/lib/std/testing.zig index 97ae914433..2279e6ef09 100644 --- a/lib/std/testing.zig +++ b/lib/std/testing.zig @@ -214,7 +214,7 @@ pub fn expectFmt(expected: []const u8, comptime template: []const u8, args: anyt /// not approximately equal to the expected value, prints diagnostics to stderr /// to show exactly how they are not equal, then returns a test failure error. /// See `math.approxEqAbs` for more informations on the tolerance parameter. -/// The types must be floating point +/// The types must be floating point. pub fn expectApproxEqAbs(expected: anytype, actual: @TypeOf(expected), tolerance: @TypeOf(expected)) !void { const T = @TypeOf(expected); @@ -246,7 +246,7 @@ test "expectApproxEqAbs" { /// not approximately equal to the expected value, prints diagnostics to stderr /// to show exactly how they are not equal, then returns a test failure error. /// See `math.approxEqRel` for more informations on the tolerance parameter. -/// The types must be floating point +/// The types must be floating point. pub fn expectApproxEqRel(expected: anytype, actual: @TypeOf(expected), tolerance: @TypeOf(expected)) !void { const T = @TypeOf(expected); @@ -719,7 +719,7 @@ pub fn checkAllAllocationFailures(backing_allocator: std.mem.Allocator, comptime } } -/// Given a type, reference all the declarations inside, so that the semantic analyzer sees them. +/// Given a type, references all the declarations inside, so that the semantic analyzer sees them. pub fn refAllDecls(comptime T: type) void { if (!builtin.is_test) return; inline for (comptime std.meta.declarations(T)) |decl| { @@ -727,8 +727,8 @@ pub fn refAllDecls(comptime T: type) void { } } -/// Given a type, and Recursively reference all the declarations inside, so that the semantic analyzer sees them. -/// For deep types, you may use `@setEvalBranchQuota` +/// Given a type, recursively references all the declarations inside, so that the semantic analyzer sees them. +/// For deep types, you may use `@setEvalBranchQuota`. pub fn refAllDeclsRecursive(comptime T: type) void { if (!builtin.is_test) return; inline for (comptime std.meta.declarations(T)) |decl| { |
