Skip to main content

luaur_ast/methods/
ast_expr_function_get_attribute.rs

1use crate::functions::find_attribute_in_array::find_attribute_in_array;
2use crate::records::ast_attr::{AstAttr, AstAttrType};
3use crate::records::ast_expr_function::AstExprFunction;
4
5impl AstExprFunction {
6    #[allow(non_snake_case)]
7    pub fn get_attribute(&self, attribute_type: AstAttrType) -> *mut AstAttr {
8        find_attribute_in_array(self.attributes, attribute_type)
9    }
10}