Commit Graph

11 Commits

Author SHA1 Message Date
Marc Tiehuis
0fda2f31aa std.math.complex: tighten existing test bounds 2024-07-30 16:30:20 +12:00
Ryan Liptak
726a1149e0 Change many test blocks to doctests/decltests 2024-02-26 15:18:31 -08:00
Ryan Liptak
16b3d1004e Remove redundant test name prefixes now that test names are fully qualified
Follow up to #19079, which made test names fully qualified.

This fixes tests that now-redundant information in their test names. For example here's a fully qualified test name before the changes in this commit:

"priority_queue.test.std.PriorityQueue: shrinkAndFree"

and the same test's name after the changes in this commit:

"priority_queue.test.shrinkAndFree"
2024-02-26 15:18:31 -08:00
expikr
ff23efe9fa Update pow.zig 2024-01-14 18:09:26 -08:00
Andrew Kelley
d29871977f remove redundant license headers from zig standard library
We already have a LICENSE file that covers the Zig Standard Library. We
no longer need to remind everyone that the license is MIT in every single
file.

Previously this was introduced to clarify the situation for a fork of
Zig that made Zig's LICENSE file harder to find, and replaced it with
their own license that required annual payments to their company.
However that fork now appears to be dead. So there is no need to
reinforce the copyright notice in every single file.
2021-08-24 12:25:09 -07:00
aiz
5414bd48ed
std.math.Complex: Change new() to init() 2021-05-17 21:57:51 +02:00
Veikka Tuominen
fd77f2cfed std: update usage of std.testing 2021-05-08 15:15:30 +03:00
Frank Denis
6c2e0c2046 Year++ 2020-12-31 15:45:24 -08:00
LemonBoy
ff14451b4a std: Implement more useful approxEq semantics
Comparisons with absolute epsilons are usually useful when comparing
numbers to zero, for non-zero numbers it's advised to switch to relative
epsilons instead to obtain meaningful results (check [1] for more
details).

The new API introduces approxEqAbs and approxEqRel, where the former
aliases and deprecated the old `approxEq`, allowing the user to pick the
right tool for the job.

The documentation is meant to guide the user in the choice of the
correct alternative.

[1] https://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/
2020-11-05 16:08:49 +01:00
Andrew Kelley
4a69b11e74 add license header to all std lib files
add SPDX license identifier
copyright ownership is zig contributors
2020-08-20 16:07:04 -04:00
Andrew Kelley
ed36dbbd9c
mv std/ lib/
that's all this commit does. further commits will fix cli flags and
such.

see #2221
2019-09-25 23:35:41 -04:00