Add exact units, signed time, and interval type-system core - #44
Merged
Merged
Conversation
isomorphisms
commented
Aug 29, 2026
isomorphisms
left a comment
Owner
Author
There was a problem hiding this comment.
Self-check boundary: this PR intentionally implements only the exact rational/unit, signed-duration/instant, and additive interval kernels. Do not broaden it to calendar semantics, probability distributions, general uncertainty, or algebraic interface inheritance merely to make the first slice feel complete. Compiler failures should be repaired minimally without weakening the pinned equations.
isomorphisms
commented
Aug 29, 2026
This was referenced Aug 29, 2026
This was referenced Aug 29, 2026
Replace opaque TTImp I-prefixed constructor and helper names with readable elaboratable-term vocabulary. Preserve public reflection spellings and serialized compatibility names. Validated with ./_/edric all.
Spell out the compiler-internal administrative-normal-form datatype, constructors, alternatives, definitions, and conversion helpers. Correct the TTImp spelling from Elaboratable to Elaborable while preserving the Compiler.ANF module path, public reflection compatibility names, and checked-in bootstrap output. Validated by both clean-commit compiler builds, source-layout checks, the self-hosting bootstrap, and edric001-edric006 plus edric009.
Resolve the repository-layout move by relocating the already-verified edric007 fixture and examples under _/, adapting the harness/workflow paths, and leaving UnitsTimeIntervals.idric and Tests.idric byte-identical to a3ffc1c.
Make Number, Text, and Data.Text native Idriç vocabulary
Add quadratic and Hermitian form semantics
…ntics Establish complex-coordinate and projective semantics
…urface Use ±Number in presheaf fixture
Generalize presheaf section payloads
Add pair arithmetic construction example
…agreement Connect exact complex fixture to pair arithmetic
…g-note Add Edriç memory-tiering lowering note
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.
Scope
Small tests-first implementation of the algebraically settled slice from #28, #30, and #31.
Exact quantities / dimensions
gallon / secondtypechecks asVolume / Timewithout a special compound-unit class.Time
Instantkept distinct from signedDuration;No Group/Semigroup inheritance hierarchy is added. The algebraic classification can remain knowledge available to later computer-science/AICI reasoning while ordinary source only sees the operations it needs.
Intervals
+epsilon/-epsilonboundary vocabulary;epsilon^2 = 0) remains a separate type and is deliberately not ordered;Deliberately deferred: interval multiplication/division, outward floating rounding, correlated uncertainty (
x-xdependency), probability/Gaussian inference, calendar time, and the broader open-ended uncertainty design.Tests-first history
ae6bcfbf0e7ccae46f57a171be40b0c78fc73ab957de2109ff81b4f4bf7f2610a63d34b5278b3804edric007a3ffc1c03e040e31a0867d473611b1bf8960cca0Prior exact-head verification
The mathematical slice was VERIFIED on feature head
a3ffc1c03e040e31a0867d473611b1bf8960cca0in its then-current pull-request merge context.59ad1d9c83028ca1dbdb8ba50f486cdd7dca9425Edric type-system smoke3327750290899166698046./edric allbootstrap completed successfullyidris2/basic/edric007: success 00.854s1/1 tests successfulThe only correction after the first semantic green run was making
edric007/runexecutable; no mathematical/type semantics were weakened or changed.Reconciliation onto current Idriç
Current head:
7b7df7638aa7e464a11388da1add72d06d6a977aCurrent base incorporated:
414cefdb9b96ec71f798559f23a50fb642774597The reconciliation is a two-parent merge preserving the verified head in history. It adapts only the repository-layout move:
_/examples/units-time-intervals/;edric007to_/tests/idris2/basic/edric007/;edric007to the current_/edricsmoke list;./_/edric all.Tests.idric,UnitsTimeIntervals.idric,edric007/expected, andedric007/runare carried forward byte-for-byte froma3ffc1c03e040e31a0867d473611b1bf8960cca0, including the executable mode onedric007/run.Current acceptance boundary
The prior green receipt proves the unchanged mathematical slice on its exact old head. It is not treated as proof that the new base integration is green. Before merge, the same
Edric type-system smoke / units-time-intervalscheck must pass on current head7b7df7638aa7e464a11388da1add72d06d6a977a.No deferred interval, uncertainty, probability, calendar/time-zone, floating-rounding, or algebraic-hierarchy work is pulled into this reconciliation.
Related: #28, #30, #31, #42.