zig/lib/std/fs
Andrew Kelley 177377b6e3 rework std.ResetEvent, improve std lib Darwin integration
* split std.ResetEvent into:
   - ResetEvent - requires init() at runtime and it can fail. Also
     requires deinit().
   - StaticResetEvent - can be statically initialized and requires no
     deinitialization. Initialization cannot fail.
 * the POSIX sem_t implementation can in fact fail on initialization
   because it is allowed to be implemented as a file descriptor.
 * Completely define, clarify, and explain in detail the semantics of
   these APIs. Remove the `isSet` function.
 * `ResetEvent.timedWait` returns an enum instead of a possible error.
 * `ResetEvent.init` takes a pointer to the ResetEvent instead of
   returning a copy.
 * On Darwin, `ResetEvent` is implemented using Grand Central Dispatch,
   which is exposed by libSystem.

stage2 changes:
 * ThreadPool: use a single, pre-initialized `ResetEvent` per worker.
 * WaitGroup: now requires init() and deinit() and init() can fail.
   - Add a `reset` function.
   - Compilation initializes one for the work queue in creation and
     re-uses it for every update.
   - Rename `stop` to `finish`.
   - Simplify the implementation based on the usage pattern.
2020-12-23 16:57:18 -08:00
..
file.zig cast sendto to SendError inside send (#7481) 2020-12-22 16:47:11 -05:00
get_app_data_dir.zig Merge branch 'master' into openbsd-minimal 2020-10-17 17:38:23 +02:00
path.zig std.fs.path.extension: different behavior for ending dot 2020-12-11 18:20:57 -07:00
test.zig rework std.ResetEvent, improve std lib Darwin integration 2020-12-23 16:57:18 -08:00
wasi.zig add license header to all std lib files 2020-08-20 16:07:04 -04:00
watch.zig Merge branch 'master' into openbsd-minimal 2020-10-17 17:38:23 +02:00