Rework the path segment encoding/decoding API.- Deprecates Format.decodeSegment (returning a range of GemericPath.Segment) and added decodeSingleSegment instead, which returns a string instead.
- Adds Format.encodeSegment to encode a single path segment
Merge pull request #171 from Geod24/deprecationClean up std.json deprecation, remove DUB hack in CI
merged-on-behalf-of: Sönke Ludwig <s-ludwig@users.noreply.github.com>
Fix getFileInfo's exception handling and reduce overhead of the background work.Instead of asyncWork, now uses a worker task directly and signals the finalization of the result using message passing. This avoids the roundtrip required to return the task handle, as well as the heap allocated result buffer of Future!T.
Merge pull request #166 from vibe-d/update_compiler_supportUpdate to DMD 2.087.0 and LDC 1.6.0.
merged-on-behalf-of: Leonid Kramer <l-kramer@users.noreply.github.com>
Let all non-aio file system functions run in worker threads.This avoids stalling the event loop in case of lengthy I/O (network shares, spinning up hard drives etc).
Make async marked safe if possible and add asyncWork.asyncWork is the same as async, except that it guarantees that the computation happens in a worker thread.
FileStream: Approximate the file offset better when appendingInstead of starting at zero, start at the current file size. This offset
is stored in FileStream. It is only an approximation because concurrent
writes could advance the file without FileStream's knowledge.
Add a test that shows that the offset is approximated as expected and that
appending to an existing file works, too.
This is also a regression test which shows that appending to an existin...
Let empty block to make sure the following consumeOne succeeds.This change ensures that a return value of false guarantees the next call to consumeOne to succeed, meaning that the combination of empty/consumeOne is sound in a single-consumer scenario. This also updates the documentation to stress that tryConsumeOne is still the preferred API.
Avoid yielding in the task finalization phase. Fixes #161.Makes sure that the task finalization finishes (including notifying possibly multiple joiners) before the fiber yields, because it won't be resumed by the scheduler before the next task gets assigned to the fiber.