**Describe the bug**
ClickHouse is unable to detect syntax error in expression: `SELECT if(CAST(NULL), '2.55', NULL) AS x`, which leads to a failure.

**How to reproduce**
* Reproduces in 20.7, 20.8 version of ClickHouse
* Queries to run that lead to unexpected result

**Expected behavior**
A clear message, indicating there is a syntax error in the above expression (CAST(NULL) is not a valid logical expression).

**Error message and/or stacktrace**
The original AST-fuzzer report - https://clickhouse-test-reports.s3.yandex.net/12550/48333b29f619490fd1df50230301596e44e2af45/fuzzer/fuzzer.log#fail1

Server error log - https://clickhouse-test-reports.s3.yandex.net/12550/48333b29f619490fd1df50230301596e44e2af45/fuzzer/server.log
{
    
    if (const auto * literal = condition->as<ASTLiteral>())
    {
        if (literal->value.getType() == Field::Types::Int64 ||
            literal->value.getType() == Field::Types::UInt64)
        {
            value = literal->value.get<Int64>();
            return true;
        }
    }
    
    if (const auto * function = condition->as<ASTFunction>())
    {
        if (function->name == "CAST")
        {
            if (const auto * expr_list = function->arguments->as<ASTExpressionList>())
            {
                const ASTPtr & type_ast = expr_list->children.at(1);
                if (const auto * type_literal = type_ast->as<ASTLiteral>())
                {
                    if (type_literal->value.getType() == Field::Types::String &&