Skip to main content

resolve_chain

Function resolve_chain 

Source
pub fn resolve_chain(path: &Path) -> Result<Vec<(PathBuf, Value)>, String>
Expand description

Load path and every ancestor reachable via inherit-from:, returning them in merge order (deepest ancestor first, path itself last). The inherit-from key is removed from every returned Value.

Relative ancestor paths are resolved against the directory of the file that declared the inherit-from:. Cycles (including self-inheritance) are detected via the recursion stack and surface as an error listing the full cycle for fast diagnosis.