MCPcopy Create free account
hub / github.com/dfinity/ic-repl / parse_value

Function parse_value

src/helper.rs:315–323  ·  view source on GitHub ↗
(
    line: &str,
    start: usize,
    end: usize,
    helper: &MyHelper,
)

Source from the content-addressed store, hash-verified

313 }
314}
315fn parse_value(
316 line: &str,
317 start: usize,
318 end: usize,
319 helper: &MyHelper,
320) -> Option<(usize, Partial)> {
321 let v = line[start..end].parse::<Exp>().ok()?.eval(helper).ok()?;
322 Some((end, Partial::Val(v, line[end..].to_string())))
323}
324fn match_selector(v: &IDLValue, prefix: &str) -> Vec<Pair> {
325 match v {
326 IDLValue::Opt(_) => vec![Pair {

Callers 1

partial_parseFunction · 0.85

Calls 1

evalMethod · 0.80

Tested by

no test coverage detected