(&self)
| 425 | } |
| 426 | |
| 427 | pub fn as_function(&self) -> Option<&AstNodeRef<ast::StmtFunctionDef>> { |
| 428 | match self { |
| 429 | Self::Function(function) => Some(function), |
| 430 | _ => None, |
| 431 | } |
| 432 | } |
| 433 | |
| 434 | pub fn expect_function(&self) -> &AstNodeRef<ast::StmtFunctionDef> { |
| 435 | self.as_function().expect("expected function") |
no outgoing calls