pub fn process_overrides<'a>(
module: &'a Module,
module_info: &'a ModuleInfo,
entry_point: Option<(ShaderStage, &str)>,
pipeline_constants: &PipelineConstants,
) -> Result<(Cow<'a, Module>, Cow<'a, ModuleInfo>), PipelineConstantError>Expand description
Compact module and replace all overrides with constants.
If no changes are needed, this just returns Cow::Borrowed references to
module and module_info. Otherwise, it clones module, retains only the
selected entry point, compacts the module, edits its global_expressions
arena to contain only fully-evaluated expressions, and returns the
simplified module and its validation results.
The module returned has an empty overrides arena, and the
global_expressions arena contains only fully-evaluated expressions.