MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / parse_functions

Function parse_functions

cranelift/reader/src/parser.rs:90–94  ·  view source on GitHub ↗

Parse the entire `text` into a list of functions. Any test commands or target declarations are ignored.

(text: &str)

Source from the content-addressed store, hash-verified

88///
89/// Any test commands or target declarations are ignored.
90pub fn parse_functions(text: &str) -> ParseResult<Vec<Function>> {
91 let _tt = timing::parse_text();
92 parse_test(text, ParseOptions::default())
93 .map(|file| file.functions.into_iter().map(|(func, _)| func).collect())
94}
95
96/// Options for configuring the parsing of filetests.
97pub struct ParseOptions<'a> {

Callers 15

parseFunction · 0.85
sanityFunction · 0.85
udiv_by_zero_trapsFunction · 0.85
function_referencesFunction · 0.85
fuelFunction · 0.85
out_of_slot_write_trapsFunction · 0.85
out_of_slot_read_trapsFunction · 0.85

Calls 4

parse_testFunction · 0.85
collectMethod · 0.80
mapMethod · 0.45
into_iterMethod · 0.45

Tested by 15

sanityFunction · 0.68
udiv_by_zero_trapsFunction · 0.68
function_referencesFunction · 0.68
fuelFunction · 0.68
out_of_slot_write_trapsFunction · 0.68
out_of_slot_read_trapsFunction · 0.68