Skip to main content

luaur_analysis/methods/
data_flow_graph_builder_current_scope.rs

1use crate::records::data_flow_graph_builder::DataFlowGraphBuilder;
2use crate::records::dfg_scope::DfgScope;
3use luaur_common::macros::luau_assert::LUAU_ASSERT;
4
5impl DataFlowGraphBuilder {
6    pub fn current_scope(&mut self) -> *mut DfgScope {
7        LUAU_ASSERT!(!self.scope_stack.is_empty());
8        *self.scope_stack.last().unwrap()
9    }
10}