Skip to content

docs: add ADR-0035 on structural vs value-dependent Any conflicts#296

Merged
Reefact merged 1 commit into
mainfrom
claude/issue-226-uri-adr
Jul 26, 2026
Merged

docs: add ADR-0035 on structural vs value-dependent Any conflicts#296
Reefact merged 1 commit into
mainfrom
claude/issue-226-uri-adr

Conversation

@Reefact

@Reefact Reefact commented Jul 26, 2026

Copy link
Copy Markdown
Owner

Summary

Record, as ADR-0035, the design rule that the Any surface enforces constraint conflicts at two different points depending on the nature of the error: a structural (category) conflict is made unrepresentable at compile time through a typed progression, while a value-dependent conflict stays on the run-time exception path. Any.Uri() (PR #295) is the rule's first typed-progression application; the existing AnyString surface is its run-time counterpart. This records a decision that was established but not yet written down.

Type of change

  • Documentation

Changes

  • Add ADR-0035 — English (canonical) plus its French translation — recording the compile-time-vs-run-time constraint-enforcement rule for the Any surface, its rationale, three rejected alternatives (all-flat, all-typed, analyzer-over-flat), consequences and follow-up.
  • Add ADR-0035 to the ADR index in doc/handwritten/for-maintainers/adr/README.md.

Testing

Docs-only change — no source, project or build file is touched — so the solution build and tests were not run for this branch (they are unaffected by it).

  • dotnet build FirstClassErrors.sln
  • dotnet test FirstClassErrors.sln
  • Analyzer tests pass (FirstClassErrors.Analyzers.UnitTests)

Documentation

  • README / doc/ updated
  • No documentation change required

The ADR is the change; it ships with its French translation alongside the English canonical file, per the bilingual ADR convention. (The README.fr.md line from the template refers to the for-users guide, which this PR does not touch.)

Architecture decisions

  • New decision recorded — ADR-0035, recorded as Accepted per the maintainer's decision (the merge to main is the acceptance), rather than the default Proposed.

Related issues

Refs #226

🤖 Generated with Claude Code

https://claude.ai/code/session_01FPAdCRsiaVo2orjJwCaDnb


Generated by Claude Code

Record the rule that Any.Uri() and AnyString jointly establish: an illegal
constraint combination is made unrepresentable at compile time through a
typed progression when the illegality is structural (a mailto has no port),
and is left to the run-time ConflictingAnyConstraintException /
AnyGenerationException path when it depends on a generated value
(Numeric().StartingWith("ORD-") versus the valid "123").

Capture the decision, its rationale, the three rejected alternatives
(all-flat, all-typed, analyzer-over-flat) and the consequences in English
(canonical) with the French translation alongside, and add it to the index.

Refs: #226
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FPAdCRsiaVo2orjJwCaDnb
@Reefact
Reefact merged commit 50b3096 into main Jul 26, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants