luaur-analysis 0.1.0

Luau type checker and type inference (Rust).
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use crate::records::constraint_snapshot::ConstraintSnapshot;
use crate::records::json_emitter::JsonEmitter;
use crate::records::object_emitter::ObjectEmitter;

pub fn write_json_emitter_constraint_snapshot(
    emitter: &mut JsonEmitter,
    snapshot: &ConstraintSnapshot,
) {
    let mut o = emitter.write_object();
    o.write_pair("stringification", &snapshot.stringification);
    o.write_pair("location", &snapshot.location);
    o.write_pair("blocks", &snapshot.blocks);
    o.finish();
}