MCPcopy Create free account
hub / github.com/Amanieu/regalloc3 / parse_entity

Function parse_entity

src/debug_utils/generic_function/parse.rs:55–59  ·  view source on GitHub ↗
(pair: Pair<'_, Rule>)

Source from the content-addressed store, hash-verified

53}
54
55fn parse_entity<T: EntityRef>(pair: Pair<'_, Rule>) -> Result<T> {
56 let [number] = extract(pair, [Rule::number]);
57 let index = parse_number(number)?;
58 Ok(T::new(index))
59}
60
61fn parse_expected_entity<T: EntityRef>(pair: Pair<'_, Rule>, expected: T) -> Result<()> {
62 let span = pair.as_span();

Callers 6

parse_entity_listFunction · 0.70
parse_value_declarationFunction · 0.70
parse_opcodeFunction · 0.70
parse_operandFunction · 0.70
parse_constraintFunction · 0.70
parse_instructionFunction · 0.70

Calls 2

extractFunction · 0.70
parse_numberFunction · 0.70

Tested by

no test coverage detected