MCPcopy Create free account
hub / github.com/argumentcomputer/ix / ctor_includes_induct

Function ctor_includes_induct

crates/compile/src/graph.rs:327–347  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

325 );
326 let b_ref = Expr::cnst(n("B"), vec![]);
327 env.insert(
328 n("A"),
329 ConstantInfo::DefnInfo(DefinitionVal {
330 cnst: ConstantVal {
331 name: n("A"),
332 level_params: vec![],
333 typ: b_ref.clone(),
334 },
335 value: b_ref,
336 hints: ReducibilityHints::Opaque,
337 safety: DefinitionSafety::Safe,
338 all: vec![n("A")],
339 }),
340 );
341 let graph = build_ref_graph(&env);
342 // A references B
343 assert!(graph.out_refs[&n("A")].contains(&n("B")));
344 // B is referenced by A
345 assert!(graph.in_refs[&n("B")].contains(&n("A")));
346 // B references nothing
347 assert!(graph.out_refs[&n("B")].is_empty());
348 }
349
350 #[test]

Callers

nothing calls this directly

Calls 4

build_ref_graphFunction · 0.85
nFunction · 0.70
mk_cvFunction · 0.70
insertMethod · 0.45

Tested by

no test coverage detected