MCPcopy Create free account
hub / github.com/FuzzAnything/PromptFuzz / peek_char

Method peek_char

src/program/serde.rs:92–97  ·  view source on GitHub ↗

Look at the first character in the input without consuming it.

(&self)

Source from the content-addressed store, hash-verified

90impl<'de> Deserializer<'de> {
91 // Look at the first character in the input without consuming it.
92 pub fn peek_char(&self) -> Result<char> {
93 self.input
94 .chars()
95 .next()
96 .ok_or_else(|| eyre::eyre!("end of input"))
97 }
98
99 // Consume the first character in the input.
100 pub fn next_char(&mut self) -> Result<char> {

Callers 4

next_charMethod · 0.80
parse_vecMethod · 0.80
deserializeMethod · 0.80
to_gadget_typeFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected