`SELECT ... WHERE match(key, '^prefix...')`
should use index similarly to
`SELECT ... WHERE key LIKE 'prefix%'`
{
public:
    std::string getFunctionName() const
    {
        if (ast)
            return assert_cast<const ASTFunction *>(ast)->name;
        else
            return dag->function_base->getName();
    }
    size_t numArguments() const
    {
        if (ast)
        {
            const auto * func = assert_cast<const ASTFunction *>(ast);
            return func->arguments ? func->arguments->children.size() : 0;
        }
        else
            return dag->children.size();
    }
    Tree getArgumentAt(size_t idx) const