apply_all

Function apply_all 

Source
pub fn apply_all(src: &str) -> String
Expand description

Apply every AST-driven rewrite pass in series. Returns the rewritten source. If parsing fails at any step, returns the source unchanged from that step onward — the pipeline is best-effort.

Pass order matters: the HLSL-preserving passes (stub injection, binop truncation, UV coercion) run first so each one can re-parse the in-flight source. The “lowering” passes (array globals, local arrays, for (int …) init) emit WGSL-shaped syntax that the parser can’t re-consume, so they all share one parse via apply_lowerings and commit their edits together at the end.