MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / resolve

Function resolve

src/sql/src/names.rs:2288–2299  ·  view source on GitHub ↗
(
    catalog: &dyn SessionCatalog,
    node: N,
)

Source from the content-addressed store, hash-verified

2286/// Resolves names in an AST node using the provided catalog.
2287#[mz_ore::instrument(target = "compiler", level = "trace", name = "ast_resolve_names")]
2288pub fn resolve<N>(
2289 catalog: &dyn SessionCatalog,
2290 node: N,
2291) -> Result<(N::Folded, ResolvedIds), PlanError>
2292where
2293 N: FoldNode<Raw, Aug>,
2294{
2295 let mut resolver = NameResolver::new(catalog);
2296 let result = node.fold(&mut resolver);
2297 resolver.status?;
2298 Ok((result, ResolvedIds::new(resolver.ids)))
2299}
2300
2301/// A set of items and their corresponding collections resolved by name resolution.
2302///

Callers 15

environments.tsFile · 0.85
dockerFunction · 0.85
mzcomposeFunction · 0.85
handleSourceSubmitFunction · 0.85
handleSourceSubmitFunction · 0.85
handleSourceSubmitFunction · 0.85
sql_implFunction · 0.85
resolve_typeMethod · 0.85
describe_declareFunction · 0.85

Calls 1

foldMethod · 0.80

Tested by 4

test_normalized_createFunction · 0.68
to_planMethod · 0.68
datadrivenFunction · 0.68