pub fn resolve(
src: &str,
vars: &HashMap<String, String>,
error_prefix: &str,
) -> Result<String, String>Expand description
Recursively replaces every var(--name) and var(--name, fallback) substring in src with the matching entry from vars.
- Returns
Errfor a missing variable with no fallback. - Limits recursion to depth 16; cyclic chains return an error.
- Prepends
error_prefixto any returned error message.