Repository navigation
Add shallow JSON entry points and opt-in native numeric bridges - #29
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a shallow JSON discovery surface and the opt-in JSONBridges product: 15 authored declarations, with no removed or changed declarations in the native public-symbol comparison. Existing calls remain supported; each throwing facade delegates once to the existing authority with caller options/limits unchanged.
JSON gains String/Data/byte parsing, checked object construction, exact decimal-text construction, pre-parsed Pointer navigation, exact-key membership and three-state presence composition. CompiledJSONSchema gains validation on its existing immutable offline plan. JSONBridges depends only on JSON and adds five explicit integer/Double/Foundation Decimal conversions. Trusted integer construction remains unmetered; Double round-trip decimal text is distinguished from its exact binary rational, and projection defaults to exact policy.
The generic JSON.number integer overload is deliberately deferred: Swift 6.4 changes existing .number(42) resolution from the enum case to that overload. Typed and inferred enum-case function references, old Codable calls and opt-in import isolation compile in debug and release. No Float widening, exact-binary source conversion, implicit null/defaulting, type erasure, new conformance or external dependency is added.
Validation at 5575ad3:
6bfe942e10f7514add396603fd83eeb95878c89e7965e6c010f5e6321092d9f2, 1,312,562 bytes, 901 source files plus manifest.The compiler harness now asks SwiftPM for actual build-products paths rather than assuming macOS directory names, and preserves its positive/negative compiler receipts in CI artifacts. The final harness corrections do not change library sources, tests or manifest.
See the compiled ergonomics crosswalk and linked guides. Suitable for an additive minor release following maintainer review and integration. This PR remains draft for that review; no merge, tag or publication is requested. Parallel CLI/preview work and branch protection are untouched.