HydroRoll-Team / HydroRoll-Team/OneRoll

Run bounded repeat functions and conditional instruction blocks

Open
#43 0 comments 0 reactions 0 assignees View on GitHub
area:engine area:language area:python blocked breaking-change priority:p1 type:feature workflow:afk
Dominant language
Python
Stars
3
Forks
1
Avg merge
3d 4h
Merged PRs (30d)
2

Description

## Parent

- #7

## What to build

Add structured control flow through `repeat(count; instruction; ...)` and validator-driven conditional blocks, reusing Program and Instruction evaluation under one ExecutionContext. Keep backward jump `@` reserved and rejected.

## Frozen contract

- Repeat count is scalar-compatible and non-negative; zero executes no body.
- Repeat returns one nested Values entry per iteration with body values in source order.
- Aggregate conditionals execute one branch; each-scope conditionals map one same-kind atom per subject.
- Conditional block `${0}` is a read-only lexical subject binding.
- Missing false block is identity and unselected branches are never evaluated.

## Acceptance criteria

- [ ] Repeat and conditional RFC case IDs pass in Rust and installed Python.
- [ ] Nested calls/blocks charge parse, AST, nesting, instruction, work, RNG, collection, trace, and output limits.
- [ ] Wrong-kind, negative-count, budget, cancellation, and branch errors are structured and atomic.
- [ ] Rust/Python results preserve nested trace structure; CLI rendering remains bounded.
- [ ] Scheduling never changes seeded evaluation order.
- [ ] `@` returns the reserved-jump migration diagnostic.

## Blocked by

- #7
- #4
- #38
- #41

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading blocked issues #7, #4, #38, and #41 to understand the existing Program, Instruction, validator, and execution model. Locate the Rust and installed Python RFC cases mentioned in the acceptance criteria, then verify repeat, conditional, limit, error, trace, CLI, and reserved-jump behavior against the frozen contract.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, rust
Domain
backend, cli, compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.