getVisibility: any `visibility_modifier` child with one of the three texts; none → public (the php default).
(&self, node: Node)
| 430 | /// getVisibility: any `visibility_modifier` child with one of the three |
| 431 | /// texts; none → public (the php default). |
| 432 | fn visibility_of(&self, node: Node) -> u8 { |
| 433 | for i in 0..node.child_count() { |
| 434 | let Some(child) = node.child(i) else { continue }; |
| 435 | if child.kind() == "visibility_modifier" { |
| 436 | match self.text(child) { |
| 437 | "public" => return 1, |
| 438 | "private" => return 2, |
| 439 | "protected" => return 3, |
| 440 | _ => {} |
| 441 | } |
| 442 | } |
| 443 | } |
| 444 | 1 // PHP defaults to public |
| 445 | } |
| 446 | |
| 447 | fn is_static(&self, node: Node) -> bool { |
| 448 | (0..node.child_count()) |
no test coverage detected