luaur-analysis 0.1.3

Luau type checker and type inference (Rust).
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use crate::records::cfg_allocator::CfgAllocator;
use crate::records::cfg_builder::CfgBuilder;
use crate::records::symbol::Symbol;
use crate::type_aliases::def_id_control_flow_graph::DefId;

impl CfgBuilder {
    pub fn new_definition(&mut self, sym: Symbol) -> DefId {
        let version = self.next_version_index(sym.clone());
        let allocator = unsafe { &mut *self.allocator };
        allocator.new_definition(sym, version)
    }
}