mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 14:24:45 +00:00
update all of the outdated deps
This commit is contained in:
parent
ed22b7d3c9
commit
6f50b877fe
37 changed files with 266 additions and 538 deletions
|
@ -9,7 +9,7 @@ use super::{
|
|||
mark_id_ast_id_map::MarkIdAstIdMap,
|
||||
};
|
||||
|
||||
use crate::markup_error::{ExpectedTextNode, NestedNodeMissingChild, NestedNodeRequired};
|
||||
use crate::markup_error::{ExpectedTextNodeSnafu, NestedNodeMissingChildSnafu, NestedNodeRequiredSnafu};
|
||||
use itertools::Itertools;
|
||||
use roc_ast::{
|
||||
lang::{core::ast::ASTNodeId, env::Env},
|
||||
|
@ -134,14 +134,14 @@ impl MarkupNode {
|
|||
Ok((child_index, closest_ast_child_index + 1))
|
||||
}
|
||||
} else {
|
||||
NestedNodeMissingChild {
|
||||
NestedNodeMissingChildSnafu {
|
||||
node_id: mark_node_id,
|
||||
children_ids: children_ids.clone(),
|
||||
}
|
||||
.fail()
|
||||
}
|
||||
}
|
||||
_ => NestedNodeRequired {
|
||||
_ => NestedNodeRequiredSnafu {
|
||||
node_type: self.node_type_as_string(),
|
||||
}
|
||||
.fail(),
|
||||
|
@ -171,7 +171,7 @@ impl MarkupNode {
|
|||
pub fn get_content_mut(&mut self) -> MarkResult<&mut String> {
|
||||
match self {
|
||||
MarkupNode::Text { content, .. } => Ok(content),
|
||||
_ => ExpectedTextNode {
|
||||
_ => ExpectedTextNodeSnafu {
|
||||
function_name: "set_content".to_owned(),
|
||||
node_type: self.node_type_as_string(),
|
||||
}
|
||||
|
@ -189,7 +189,7 @@ impl MarkupNode {
|
|||
if let MarkupNode::Nested { children_ids, .. } = self {
|
||||
children_ids.splice(index..index, vec![child_id]);
|
||||
} else {
|
||||
NestedNodeRequired {
|
||||
NestedNodeRequiredSnafu {
|
||||
node_type: self.node_type_as_string(),
|
||||
}
|
||||
.fail()?;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue