MCPcopy Create free account
hub / github.com/PLSysSec/wave / is_part_of_rust_expr

Method is_part_of_rust_expr

tools/fuzz-gen/src/specifications/preparser.rs:376–387  ·  view source on GitHub ↗

is there any non-prusti operator following the first thing?

(&mut self)

Source from the content-addressed store, hash-verified

374
375 /// is there any non-prusti operator following the first thing?
376 fn is_part_of_rust_expr(&mut self) -> bool {
377 if let Some(token) = self.tokens.pop_front() {
378 let result = !(self.peek_operator("|=") ||
379 self.peek_operator("&&") ||
380 self.peek_operator("==>") ||
381 self.tokens.front().is_none());
382 self.tokens.push_front(token);
383 result
384 } else {
385 false
386 }
387 }
388 /// does the given operator appear in the stream at top level
389 fn contains_operator(&self, stream: &VecDeque<TokenTree>, operator: &str) -> bool {
390 (0..stream.len()).any(|offset: usize| self.peek_operator_stream_offset(stream, operator, offset))

Callers 1

parse_entailmentMethod · 0.80

Calls 1

peek_operatorMethod · 0.80

Tested by

no test coverage detected