Skip to main content

i_slint_compiler/
llr.rs

1// Copyright © SixtyFPS GmbH <info@slint.dev>
2// SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0
3
4// cSpell: ignore optim
5//! The Low Level Representation module
6
7pub mod debug_info;
8mod expression;
9pub use expression::*;
10mod item_tree;
11pub use item_tree::*;
12pub mod lower_expression;
13pub mod lower_layout_expression;
14pub mod lower_to_item_tree;
15pub mod pretty_print;
16
17/// The optimization passes over the LLR
18pub mod optim_passes {
19    pub mod count_property_use;
20    mod inline_expressions;
21    mod remove_unused;
22
23    pub fn run_passes(root: &mut super::CompilationUnit) {
24        count_property_use::count_property_use(root);
25        inline_expressions::inline_simple_expressions(root);
26        remove_unused::remove_unused(root);
27    }
28}