Claude/publish spec interpreter eg9jk#19
Merged
hyperpolymath merged 2 commits intomainfrom Dec 27, 2025
Merged
Conversation
Add a condensed language specification (SPEC.md) and release documentation (RELEASE.md) for the first public release of the AffineScript reference parser. New examples demonstrate additional language features: - effects.as: Effect handling with State and Exn - traits.as: Traits, type classes, and bounded polymorphism - refinements.as: Refinement types and compile-time verification This provides a minimal publishable package with: - Complete lexer and parser (reference implementation) - Language specification covering syntax and semantics - Comprehensive examples covering all major features
Add golden test infrastructure that compares parser AST output against expected files for regression testing. New test infrastructure: - test/test_golden.ml: Golden test runner with span normalization - test/golden/: Directory containing .as source and .expected AST files Golden tests cover: - hello.as: Basic function declaration - literals.as: All literal types (int, float, bool, string, char, unit) - binary_ops.as: Operators and precedence - functions.as: Function declarations (simple, total, generic, public) - types.as: Type declarations (alias, struct, enum) - effects.as: Effect declarations with operations - patterns.as: Pattern matching (literals, destructuring, constructors) - traits.as: Trait declarations and implementations - ownership.as: Ownership modifiers (own, ref, mut) - rows.as: Row polymorphism syntax - lambda.as: Lambda expressions - imports.as: Module imports Also adds example parse tests that verify all examples/*.as files parse successfully without checking specific AST structure.
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.
No description provided.