- CompletableDeferred.completeExceptionally(exception): fails the deferred
with a Lyng exception; the original exception object is preserved as
errorObject so assertThrows/catch see the correct class (works for both
built-in ObjException and user-declared class instances)
- LaunchPool: add maxQueueSize parameter (suspends launch when full),
add cancelAndJoin() for graceful shutdown that waits for running tasks,
clarify all semantics in the extern declaration comments
- Two tests for completeExceptionally (built-in and user-defined exception)
- Fix parallelism.md channel doc-test to be illustration-only (avoid
flakiness from coroutine scheduling in the doc-test runner)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Provides a pure Kotlin/KMP SHA-1 implementation with no extra dependencies,
exposed as `LegacyDigest.sha1(data)` in the `lyng.legacy_digest` package.
The naming deliberately signals that SHA-1 is cryptographically broken:
the object name `LegacyDigest` and prominent doc-comment warnings steer
users away from security-sensitive use while still enabling interoperability
with legacy protocols and file formats that require SHA-1.
API:
import lyng.legacy_digest
val hex: String = LegacyDigest.sha1("some string") // UTF-8 input
val hex: String = LegacyDigest.sha1(someBuffer) // raw-byte input
Tests cover FIPS 180-4 known-answer vectors (empty, "abc", long message,
quick-brown-fox) at both the Kotlin and Lyng integration levels.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>