-
Notifications
You must be signed in to change notification settings - Fork 31
whatever the heck I was doing #258
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
nikomatsakis
wants to merge
41
commits into
dada-lang:main
Choose a base branch
from
nikomatsakis:main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
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
Establishes .ongoing/ directory for tracking work that spans multiple sessions and adds detailed documentation of the type inference constraint system. Also removes unused predicate tracking from inference variables. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
When we require a permission is a given predicate, we do not put that permission into a surrounding context
VSCode's ansi preview mode still works.
Refactor test result handling to distinguish between passed tests, failed tests, and FIXME tests. When a test marked as FIXME passes, it's now reported as a test failure to alert that the bug may have been fixed and the FIXME marker should be removed. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
They desugar to a main function.
This commit restructures the documentation to provide clearer guidance for both Claude AI sessions and human contributors: - **CLAUDE.md**: Streamlined to focus on Claude-specific behavior guidelines, emphasizing checking .development/ docs first before exploring patterns. Adds instructions for multi-session work tracking. - **CONTRIBUTING.md**: Rewritten to clarify that Dada is a personal experimental project. Sets expectations about PR size and coordination needs while remaining welcoming to contributions. - **.development/**: Added comprehensive documentation structure with: - architecture.md: Compiler structure and design - patterns.md: Code conventions and established patterns - workflows.md: Build, test, and development processes - documentation.md: Rustdoc guidelines and standards - rfc.md: RFC workflow and specification development The new structure separates concerns between AI-specific instructions (CLAUDE.md), human contributor guidelines (CONTRIBUTING.md), and detailed development documentation (.development/). 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Created comprehensive documentation for the dada-parser crate to help understand its architecture and usage patterns: - Added components/dada-parser/docs/overview.md with detailed explanation of the parser's design, including: - Parse trait and its helper methods - Parse vs eat method distinction - Commitment model for error recovery - Practical examples from the codebase - Included the overview in lib.rs using doc attribute to make it discoverable via rustdoc This documentation will help future development of parser features like string interpolation by clarifying existing patterns and conventions. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit establishes the RFC process for Dada language development
and introduces the first RFC for string literal design:
**RFC Infrastructure:**
- Set up rfcs/ and spec/ directories with mdbook configuration
- Created RFC-0001 for string literals with comprehensive design
- Added ongoing work tracking in .claude/ for multi-session coordination
**RFC-0001: String Literals**
- Defines interpolated string literals as the default syntax using {}
- Supports both single ("") and triple quotes (""") variants
- Includes automatic dedenting for multiline strings starting with newline
- Provides "\" escape hatch to disable auto-dedenting
- Learning from Rust's evolution and JavaScript template literal success
The RFC includes executable examples using assert syntax and addresses
common questions about design choices. Implementation tracking files
(impl.md, spec.md, todo.md) are set up for future development work.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Added tutorial files demonstrating various Dada language features, including string interpolation examples that relate to RFC-0001: - String interpolation examples (02-hello-world-with-interpolation.dada) - Permission system tutorials (sharing, leasing, our values) - Type system examples (owned vs copy types, value type splits) - Method and trait examples - WebAssembly compilation examples Includes corresponding test reports showing current compilation status. These tutorials serve as both documentation and test cases for language features as they are implemented. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Create dada-mdbook-preprocessor to handle r[...] label processing - Replace manual CSS configuration with automated inline injection - Preprocessor scans chapters for labels and injects styles only where needed - Add site-url configuration to fix subpath rendering issues - Update deploy script to build both RFC and spec mdbooks 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Document the successful implementation of inline CSS injection approach and mark CSS consolidation task as completed. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add `cargo xtask rfc new` command that auto-finds next RFC number - Create RFC-0000 template as reusable skeleton for new RFCs - Update workflow documentation with streamlined creation process - Fix typo in string literals RFC (dicsable → disable) 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Prevents accidentally committing generated documentation files from RFC and spec book builds. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add populate_rfc_sections() to automatically generate RFC listings - Simplify SUMMARY.md to use dynamic "All RFCs" page instead of manual sections - Update RFC templates with minor formatting improvements - Track implementation progress in ongoing workflow documentation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add polished table design with status-based categorization - Implement shields.io status badges for visual RFC status indication - Create collapsible summary rows with disclosure triangles in number column - Enable proper markdown rendering in summary content with strategic newlines - Add comprehensive CSS styling with dark theme support - Integrate AI memory comment system into CLAUDE.md for persistent knowledge - Update ongoing task documentation with completion status 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This implements Phase 1-3 of the test-spec linking design from the RFC workflow: **Core Features:** - Added `spec_refs` field to `TestExpectations` struct to track spec references - Created `SpecValidator` module that scans spec mdbook and extracts all `r[...]` labels - Integrated validation into test runner with clear error reporting - Added `InvalidSpecReference` failure type for invalid spec references **Usage:** Test files can now include `#:spec topic.subtopic.detail` annotations that are validated against actual spec paragraphs. Invalid references are reported as test failures with helpful error messages. **Implementation Details:** - Parser recognizes `#:spec` configuration comments in test file headers - Validator recursively scans `spec/src/` directory for markdown files - Extracts spec IDs using regex pattern `r\[([^\]]+)\]` - Validation runs during test execution and reports failures in test reports - Added dependencies: serde, serde_yaml for future YAML processing 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add comprehensive tokenizer documentation for string literal processing - Document Parse trait commitment model and error handling patterns - Document expression parsing and literal integration - Identify missing escape sequence processing bug - Update ongoing task tracking with completed documentation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add TokenText interned struct for processed literal content
- Update TokenKind::Literal to use TokenText instead of &str
- Implement escape sequence processing in tokenizer (\n, \", \\, \t, \r, \{, \})
- Update parser to extract processed text from TokenText
- Add escape sequence test case
- Bless operator precedence test reference for new AST structure
This fixes the bug where escape sequences were validated but never interpreted.
String literals now correctly process escape sequences during tokenization while
keeping tokens Copy through Salsa interned structs.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Add design document for --porcelain flag to provide structured JSON test output that AI assistants can easily parse and act upon. Current test failures only show "Error: 1 test failure(s)" with no actionable information. Proposed solution: - JSON output with test status, failure reasons, and specific suggestions - Clear categorization of failure types (blessing vs code fixes) - Structured format for programmatic consumption - CLAUDE.md documentation for AI assistant parsing instructions Status: Design phase - needs approval before implementation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Created RFC-0002 using cargo xtask rfc new command - Documented complete RFC-to-spec integration with rfc[123] annotations - Designed interactive specification viewer with expandable RFC content - Compared mdbook vs Sphinx tooling approaches with hybrid recommendation - Validated RFC process by using it to document itself - Removed spec.md from RFC template (spec text goes in main spec) - Updated ongoing task tracking with session progress Key design elements: • RFC annotations: rfc[123] or rfc[123, 456] for concurrent development • Interactive viewer: stable default with visual RFC indicators • Test integration: prefix matching already implemented • Tooling: custom Sphinx extension for layered HTML output 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…inability Major refactoring of the test infrastructure to eliminate significant code duplication between regular and porcelain test modes while maintaining full functionality. Key improvements: - Created TestOutputFormatter trait with RegularFormatter and PorcelainFormatter - Unified test execution into single run_test() function that always captures timing and annotations - Eliminated duplicate functions: run_test_detailed, test_regular, test_porcelain - Added proper Sync + Send trait bounds for parallel execution - Moved helper functions outside impl block for better organization All functionality preserved: - Regular mode: Shows progress bars and "All X tests passed" messages - Porcelain mode: Outputs structured JSON with timing and annotations - Verbose mode: Shows individual test progress - Parallel execution: Works correctly with trait bounds Architecture improvements: - More maintainable: Single execution path, clear separation of concerns - More extensible: Easy to add new output formatters via trait - Less error-prone: No duplicate logic to keep in sync - Better tested: Single code path ensures consistent behavior ~100+ lines of duplicate code eliminated with significant maintainability gains. Two follow-up issues identified for future work: 1. Porcelain output purity: Error messages printed before JSON 2. Failure detail actionability: Assess whether to include test report content 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Simplified analyze_failure() to always return "test_failure" and point to test reports - Enhanced test reports with "🎯 Next Steps" section providing intelligent guidance - Added accurate diagnostic annotation format details (#\! syntax with regex support) - Updated CLAUDE.md with concise test failure handling guidance This moves complex failure analysis from porcelain JSON into rich test reports, making the system both simpler and more helpful for AI assistants. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Final status: PRODUCTION READY with simplified porcelain output and enhanced test reports. All follow-up issues resolved and architecture improvements documented. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Work is complete and documented in git history. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Remove verbose test output documentation and redundant sections while preserving essential actionable information. The test command and suggestion field guidance remain, but detailed JSON schema and separate failure handling sections are consolidated into a single clear sentence. Also integrate socratic-shell collaboration patterns for tracking work and authoring insightful code comments. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
These tracking files have been replaced by GitHub tracking issues dada-lang#255 and dada-lang#256, which provide better visibility and persistence. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The test used `# Surprise!` instead of `#!` for the expected error annotation, causing the test framework to not recognize it. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Replace custom `r[...]` and `rfc[...]` notation with MyST `{spec}` directive:
- `:::{spec} paragraph.id [rfcN...] [!rfcN...]` carries ID and RFC metadata
- `!rfcN` prefix marks content deleted by an RFC
- Commit to MyST/Sphinx tooling approach
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Update spec files and tooling to use the new :::{spec} directive
format as specified in RFC-0002. The mdbook preprocessor now handles
block directives with optional RFC tags for tracking changes.
Closes the first two items in dada-lang#255.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
❌ Deploy Preview for dada-lang failed. Why did it fail? →
|
Remove dead code including unused timeout_warning module and unused RfcInfo fields. Apply clippy auto-fixes for format strings, Option::map, and other minor issues. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Change &PathBuf to &Path and inline format args. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Collapse nested if statements with if-let chains per clippy guidance. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Collapse nested if statements (collapsible_if) in multiple components - Convert loop with let-else break to while let (while_let_loop) in parser - Remove stable feature flag panic_payload_as_str (stable since 1.91) - Suppress dead_code warning for Assets struct used by derive macro Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The deploy job uses mdbook to build RFC and spec documentation but wasn't installing it first. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
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.
Summary
This PR consolidates several months of local development work across multiple areas of Dada.
RFC Infrastructure & Specification Workflow
cargo xtask rfc newfor creating new RFCsdada-mdbook-preprocessorfor processing spec paragraphs and RFC annotationsr[...]notation to MyST:::{spec}directive syntaxTesting Infrastructure
--porcelainflag for structured JSON test output (AI-friendly)#:speccomment validation linking tests to spec paragraphsTestOutputFormattertrait to eliminate code duplicationParser & String Literals
\n,\",\\,\t,\r,\{,\})TokenTextinterned struct for processed literal contentType System
Language Features
main)Documentation & Developer Experience
.development/directory (architecture, patterns, workflows)Code Quality