Skip to content

20260722 generic clvm - #532

Draft
prozacchiwawa wants to merge 9 commits into
mainfrom
20260722-generic-clvm
Draft

20260722 generic clvm#532
prozacchiwawa wants to merge 9 commits into
mainfrom
20260722-generic-clvm

Conversation

@prozacchiwawa

@prozacchiwawa prozacchiwawa commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Note

High Risk
Large, cross-cutting refactor of the classic compiler, optimizer, and module loader—behavior-sensitive paths where subtle generic/import-export mistakes could change compilation or diagnostics.

Overview
Introduces ClassicAllocator in abstraction.rs as the shared interface for classic CLVM tooling: abstract NodePtr, ASExp, import/export to clvm_rs::Allocator, and ClError(Srcloc, EvalErr) on list/atom construction and traversal errors.

Stage-2 pipeline (compile, optimize, module, helpers, inline, reader, defaults) and shared utilities (sexp, pattern_match, debug, operators) are rewritten to take A: ClassicAllocator instead of &mut Allocator directly. Node handles are passed by reference; allocator.loc is supplied when building atoms/pairs. TRunProgram still runs on the raw allocator via export on inputs and import on results.

do_com_prog / do_optimize now return Result<NodePtr, ClError> (no Reduction/Response wrapper at that layer). FunctionExtraInfo and related debug/symbol dump paths are generic over the allocator type. clvm_rs::Allocator implements ClassicAllocator as identity import/export with a default *clvm* source location.

Reviewed by Cursor Bugbot for commit a50e981. Bugbot is set up for automated code reviews on this repo. Configure here.

@socket-security

socket-security Bot commented Jul 24, 2026

Copy link
Copy Markdown

No dependency changes detected. Learn more about Socket for GitHub.

👍 No dependency changes detected in pull request

Comment thread Cargo.toml Outdated

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 4eb95ac. Configure here.

Comment thread src/classic/clvm_tools/stages/stage_2/optimize.rs Outdated
@prozacchiwawa
prozacchiwawa marked this pull request as draft July 25, 2026 00:45
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.

1 participant