Found by branch review of conveyor-engine before merge (the in-flight XMILE conveyor+queue implementation; specs docs/design/conveyors.md + docs/design/queues.md). Filed from a review report that exceeded its 15-finding cap. (This item came from the design/spec sweep, not from an evidence JSON.)
Summary
docs/design/conveyors.md section 7.2 specifies explicit per-slat / per-time-unit list initialization of a conveyor's contents. The runtime core implements it (ConveyorState::init_explicit / spread_per_time_unit, src/simlin-engine/src/conveyor.rs:527), but the code path is unreachable: init_belts always calls init_steady with the scalar stock value (src/simlin-engine/src/conveyor_compile.rs:1844-1850), and a comma-list <eqn> does not parse as a scalar equation. The spec'd initialization form therefore cannot be used.
Failure scenario / cost
A modeler who writes the section 7.2 explicit-list initial equation for a conveyor stock gets either a parse/compile error or a silently steady-state-initialized belt, never the per-slat distribution the spec describes. The implemented init_explicit/spread_per_time_unit machinery is dead code that no input can reach.
Evidence
- implemented but unreached:
ConveyorState::init_explicit / spread_per_time_unit (src/simlin-engine/src/conveyor.rs:527)
- the only initializer wired in is steady-state:
init_belts calls init_steady with the scalar stock value (src/simlin-engine/src/conveyor_compile.rs:1844-1850)
- a comma-list
<eqn> is not a scalar equation, so no valid input reaches init_explicit
Suggested direction
Either wire the explicit-list initial equation form through init_belts to init_explicit/spread_per_time_unit, or (if section 7.2 is being deferred) mark the spec section as not-yet-implemented and note the dead runtime code so it is not mistaken for reachable behavior.
Found by branch review of
conveyor-enginebefore merge (the in-flight XMILE conveyor+queue implementation; specsdocs/design/conveyors.md+docs/design/queues.md). Filed from a review report that exceeded its 15-finding cap. (This item came from the design/spec sweep, not from an evidence JSON.)Summary
docs/design/conveyors.mdsection 7.2 specifies explicit per-slat / per-time-unit list initialization of a conveyor's contents. The runtime core implements it (ConveyorState::init_explicit/spread_per_time_unit,src/simlin-engine/src/conveyor.rs:527), but the code path is unreachable:init_beltsalways callsinit_steadywith the scalar stock value (src/simlin-engine/src/conveyor_compile.rs:1844-1850), and a comma-list<eqn>does not parse as a scalar equation. The spec'd initialization form therefore cannot be used.Failure scenario / cost
A modeler who writes the section 7.2 explicit-list initial equation for a conveyor stock gets either a parse/compile error or a silently steady-state-initialized belt, never the per-slat distribution the spec describes. The implemented
init_explicit/spread_per_time_unitmachinery is dead code that no input can reach.Evidence
ConveyorState::init_explicit/spread_per_time_unit(src/simlin-engine/src/conveyor.rs:527)init_beltscallsinit_steadywith the scalar stock value (src/simlin-engine/src/conveyor_compile.rs:1844-1850)<eqn>is not a scalar equation, so no valid input reachesinit_explicitSuggested direction
Either wire the explicit-list initial equation form through
init_beltstoinit_explicit/spread_per_time_unit, or (if section 7.2 is being deferred) mark the spec section as not-yet-implemented and note the dead runtime code so it is not mistaken for reachable behavior.