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

Method is_mutable_list

src/program/array.rs:12–28  ·  view source on GitHub ↗
(&self, node: &Node)

Source from the content-addressed store, hash-verified

10
11impl InitListExpr {
12 pub fn is_mutable_list(&self, node: &Node) -> bool {
13 for child in &node.inner {
14 let child = child.ignore_cast().ignore_parent();
15 if !matches!(
16 &child.kind,
17 Clang::StringLiteral(_)
18 | Clang::CharacterLiteral(_)
19 | Clang::FloatingLiteral(_)
20 | Clang::IntegerLiteral(_)
21 | Clang::InitListExpr(_)
22 | Clang::UnaryOperator(_)
23 ) {
24 return false;
25 }
26 }
27 true
28 }
29
30 pub fn get_childs<'a>(&self, node: &'a Node) -> Vec<&'a Node> {
31 let mut childs: Vec<&Node> = Vec::new();

Callers 2

Calls 2

ignore_parentMethod · 0.80
ignore_castMethod · 0.80

Tested by

no test coverage detected