pub fn fn_owning_scope_for<'a>(
ctx: &'a CodegenContext,
fd: &FnDef,
) -> Option<&'a str>Expand description
Round-6: resolve a &FnDef’s owning scope by pointer comparison
against ctx.modules[*].fn_defs. Pointer-eq sidesteps the
bare-name collision — &CountdownA.fn_defs[0] and
&CountdownB.fn_defs[0] are distinct addresses even with
fd.name = "countdown" in both.
Returns None when the fd is not in any dep module — entry
items, synthesized buffered variants, and extra_fn_defs all
fall through. Callers treat None as “entry scope”.