Skip to main content

luaur_analysis/methods/
refinement_arena_conjunction_control_flow_graph.rs

1//! Source: `Analysis/src/ControlFlowGraph.cpp:28-31` (hand-ported)
2//! C++ `RefinementId RefinementArena::conjunction(RefinementId lhs, RefinementId rhs)`.
3use crate::records::conjunction_control_flow_graph::Conjunction;
4use crate::records::refinement_arena_control_flow_graph::RefinementArena;
5use crate::type_aliases::refinement_control_flow_graph::Refinement;
6use crate::type_aliases::refinement_id_control_flow_graph::RefinementId;
7
8impl RefinementArena {
9    pub fn conjunction_mut(&mut self, lhs: RefinementId, rhs: RefinementId) -> RefinementId {
10        // C++: return NotNull{allocator.allocate(Conjunction{lhs, rhs})};
11        self.allocator
12            .allocate(Refinement::Conjunction(Conjunction { lhs, rhs }))
13    }
14}