Debian Codegraph @

src/iter/operation_errors.rs

raw symbols SCIP
1 use craterust-analyzer cargo rrule 0.14.0 crate/::RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#;
2
3 pub(craterust-analyzer cargo rrule 0.14.0 crate/) fn checked_mul_u32rust-analyzer cargo rrule 0.14.0 iter/operation_errors/checked_mul_u32().(v1: u32, v2: u32, hint: Optionrust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#<&str>) -> Resultrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#<u32, RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#> {
4 v1.checked_mulrust-analyzer cargo core https://github.com/rust-lang/rust/library/core num/impl#[u32]checked_mul().(v2).ok_or_elserust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/impl#[`Option<T>`]ok_or_else().(|| match hint {
5 Somerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#Some#(hint) => RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#::new_iter_errrust-analyzer cargo rrule 0.14.0 error/impl#[RRuleError]new_iter_err().(formatrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc macros/format!!(
6 "Could not multiply number, would overflow (`{} * {}`), {}.",
7 v1, v2, hint
8 )),
9 Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None# => RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#::new_iter_errrust-analyzer cargo rrule 0.14.0 error/impl#[RRuleError]new_iter_err().(formatrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc macros/format!!(
10 "Could not multiply number, would overflow (`{} * {}`).",
11 v1, v2,
12 )),
13 })
14 }
15
16 pub(craterust-analyzer cargo rrule 0.14.0 crate/) fn checked_add_u32rust-analyzer cargo rrule 0.14.0 iter/operation_errors/checked_add_u32().(v1: u32, v2: u32, hint: Optionrust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#<&str>) -> Resultrust-analyzer cargo core https://github.com/rust-lang/rust/library/core result/Result#<u32, RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#> {
17 v1.checked_addrust-analyzer cargo core https://github.com/rust-lang/rust/library/core num/impl#[u32]checked_add().(v2).ok_or_elserust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/impl#[`Option<T>`]ok_or_else().(|| match hint {
18 Somerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#Some#(hint) => RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#::new_iter_errrust-analyzer cargo rrule 0.14.0 error/impl#[RRuleError]new_iter_err().(formatrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc macros/format!!(
19 "Could not add numbers, would overflow (`{} + {}`), {}.",
20 v1, v2, hint
21 )),
22 Nonerust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#None# => RRuleErrorrust-analyzer cargo rrule 0.14.0 error/RRuleError#::new_iter_errrust-analyzer cargo rrule 0.14.0 error/impl#[RRuleError]new_iter_err().(formatrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc macros/format!!(
23 "Could not add numbers, would overflow (`{} + {}`).",
24 v1, v2,
25 )),
26 })
27 }