Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/wright-analyzer/src/canonical.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ pub use cfg::BLOCK_KINDS;
pub(crate) use cfg::matching_end;
pub use service::{SemanticService, span_json};
pub use symbols::*;
pub(crate) use traversal::{dead_actions, unwrapped};
pub(crate) use traversal::{dead_actions, unwrapped, value_children, visit_action_roots};
pub use traversal::{live_actions, subroutine_callee};
2 changes: 1 addition & 1 deletion crates/wright-analyzer/src/canonical/symbols.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ pub struct SemanticIndex {
next_value_id: ValueId,
}

pub(super) fn value_identity_map(program: &Program) -> HashMap<usize, ValueId> {
pub(crate) fn value_identity_map(program: &Program) -> HashMap<usize, ValueId> {
let mut identities = HashMap::new();
for rule in &program.rules {
for condition in &rule.conditions {
Expand Down
4 changes: 2 additions & 2 deletions crates/wright-analyzer/src/canonical/traversal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ pub fn subroutine_callee(action: &Action) -> Option<&str> {
}
}

pub(super) fn visit_action_roots<'a>(action: &'a Action, visit: &mut impl FnMut(usize, &'a Value)) {
pub(crate) fn visit_action_roots<'a>(action: &'a Action, visit: &mut impl FnMut(usize, &'a Value)) {
match action {
Action::SetGlobalVariable { value, .. } | Action::ModifyGlobalVariable { value, .. } => {
visit(0, value)
Expand Down Expand Up @@ -125,7 +125,7 @@ pub(super) fn visit_value_tree<'a>(
visit_value_tree_at(value, parent, &mut path, visit);
}

pub(super) fn value_children(value: &Value) -> Vec<&Value> {
pub(crate) fn value_children(value: &Value) -> Vec<&Value> {
match value {
Value::Array(values) | Value::Call { args: values, .. } => values.iter().collect(),
Value::Vector { x, y, z } => vec![x, y, z],
Expand Down
Loading
Loading