Skip to content

refactor: remove dead event simulation and tighten helper visibility - #142

Open
google-labs-stitch[bot] wants to merge 1 commit into
mainfrom
stitch/remove-dead-event-simulation-and-helpers-jm1-52d7d0e2-7858-4cb1-ae87-5bafeff6569f
Open

google-labs-stitch[bot] wants to merge 1 commit into
mainfrom
stitch/remove-dead-event-simulation-and-helpers-jm1-52d7d0e2-7858-4cb1-ae87-5bafeff6569f

Conversation

@google-labs-stitch

Copy link
Copy Markdown
Contributor

Summary

This change removes dead event simulation code, dead dwell resets and extra pub(crate) visibility across six internal modules. Public Rust exports, WebAssembly bindings, TypeScript declarations, error priority and sample-exact audio outputs do not change.

Changes

  • Remove ParameterControl::apply_to and validate_in_sequence from src/events.rs, and call event.event.validate() directly in ValidatedEvents::new.
  • Remove the ProcessorConfig argument from ValidatedEvents::new in src/events.rs and Processor::validate in src/processor.rs.
  • Remove the ProcessorConfig argument from decode_events and its six callers in src/wasm.rs.
  • Remove the unread zero assignments to previous_scale_index and previous_octave in Resynthesis::reset_audio in src/resynthesis.rs.
  • Remove Resynthesis::reset_dwell and set self.dwell = Q14::ZERO at the three guard sites in Resynthesis::select_target_ratio.
  • Make validate_chromatic_intervals and validate_diatonic_intervals private in src/harmony.rs, and make Formant::remove_glottal private in src/formant.rs.

Verification

  • cargo fmt --check
  • cargo rustc --locked --lib --release -- -D warnings
  • cargo clippy --locked --lib -- -D warnings
  • RUSTDOCFLAGS="-D warnings" cargo doc --locked --no-deps
  • cargo package --locked
  • RUSTDOCFLAGS="-D warnings" npm run check:wasm
  • npm run verify:pack
  • MSRV 1.88 builds (cargo build --locked --lib and --target wasm32-unknown-unknown --features wasm)
  • External /tmp equivalence harness against baseline HEAD across event validation errors, Feedback, Telemetry, formant envelopes and i16/f32 PCM outputs, plus Node.js Wasm binding checks across all six process* methods

Automated PR initiated by user @byteland-app via Stitch Loop.

- Remove ParameterControl::apply_to and validate_in_sequence.
- Remove the ProcessorConfig argument from ValidatedEvents::new.
- Remove the ProcessorConfig argument from Wasm decode_events.
- Remove Resynthesis::reset_dwell and the dead dwell resets.
- Make the harmony interval validators and remove_glottal private.
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.

0 participants