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

Method match_ieee64

cranelift/reader/src/parser.rs:868–877  ·  view source on GitHub ↗

Match and consume an Ieee64 immediate.

(&mut self, err_msg: &str)

Source from the content-addressed store, hash-verified

866
867 // Match and consume an Ieee64 immediate.
868 fn match_ieee64(&mut self, err_msg: &str) -> ParseResult<Ieee64> {
869 if let Some(Token::Float(text)) = self.token() {
870 self.consume();
871 // Lexer just gives us raw text that looks like a float.
872 // Parse it as an Ieee64 to check for the right number of digits and other issues.
873 text.parse().map_err(|e| self.error(e))
874 } else {
875 err!(self.loc, err_msg)
876 }
877 }
878
879 // Match and consume an Ieee128 immediate.
880 fn match_ieee128(&mut self, err_msg: &str) -> ParseResult<Ieee128> {

Callers 2

parse_data_valueMethod · 0.80
parse_inst_operandsMethod · 0.80

Calls 4

tokenMethod · 0.80
consumeMethod · 0.45
parseMethod · 0.45
errorMethod · 0.45

Tested by

no test coverage detected