| 8777 | } |
| 8778 | |
| 8779 | xpath_ast_node* parse_function_helper(ast_type_t type0, ast_type_t type1, size_t argc, xpath_ast_node* args[2]) |
| 8780 | { |
| 8781 | assert(argc <= 1); |
| 8782 | |
| 8783 | if (argc == 1 && args[0]->rettype() != xpath_type_node_set) throw_error("Function has to be applied to node set"); |
| 8784 | |
| 8785 | return new (alloc_node()) xpath_ast_node(argc == 0 ? type0 : type1, xpath_type_string, args[0]); |
| 8786 | } |
| 8787 | |
| 8788 | xpath_ast_node* parse_function(const xpath_lexer_string& name, size_t argc, xpath_ast_node* args[2]) |
| 8789 | { |