Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 5 additions & 10 deletions src/v2/lens/production_qualification_origin_probe.dag
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ import v2.std.node {
Positional,
TypeNode,
fold_node,
Symbol,
symbol_eq,
symbol_intern_lexeme,
symbol_lexeme,
}
Expand Down Expand Up @@ -204,13 +206,6 @@ fn maybe_snoc_site_row(
}
}

fn node_contains_atom_text(node: Node, wanted: String) -> Bool {
any(
xs: atom_identities_in_node(node: node),
predicate: fn(sym) { string_eq(a: symbol_lexeme(sym: sym), b: wanted) }
)
}

fn maybe_snoc_callee_text(callees: List<String>, text: String) -> List<String> {
if contains(xs: callees, item: text, eq: string_eq) {
callees
Expand Down Expand Up @@ -261,10 +256,10 @@ fn decl_callee_refusals(decl: FnArrowDecl) -> List<Diagnostic> {
origin_probe_callees_from_decl(decl: decl).refusals
}

fn decl_contains_atom(decl: FnArrowDecl, atom: String) -> Bool {
fn decl_contains_atom(decl: FnArrowDecl, atom: Symbol) -> Bool {
any(
xs: atom_identities_in_subtree(node: decl.output),
predicate: fn(sym) { string_eq(a: symbol_lexeme(sym: sym), b: atom) }
predicate: fn(sym) { symbol_eq(a: sym, b: atom) }
)
}

Expand All @@ -283,7 +278,7 @@ data direct_rust_door_target_model_callee: String = "direct_rust_door_target_mod

// FixtureDerived requires the direct_rust_door_inferred_tree fixture-tree marker atom in the fn-arrow skeleton. Target-model choice (direct_rust_door_target_model) is NOT an origin proxy — mint_written + target without the fixture-tree marker classifies UnknownOrigin.
fn decl_has_fixture_marker(decl: FnArrowDecl) -> Bool {
decl_contains_atom(decl: decl, atom: direct_rust_door_inferred_tree_atom)
decl_contains_atom(decl: decl, atom: symbol_intern_lexeme(lexeme: direct_rust_door_inferred_tree_atom))
}

fn decl_origin_from_structure(decl: FnArrowDecl) -> ProductionQualificationOrigin {
Expand Down