Reproduction steps:
```
CREATE TABLE table_left                                                                                                                                                                                              
(                                                                                                                                                                                                                    
    `date` Date,                                                                                                                                                                                                     
    `uid` String                                                                                                                                                                                                     
)                                                                                                                                                                                                                    
ENGINE = MergeTree()                                                                                                                                                                                                 
ORDER BY (date, uid)          
                                                                                                                                                                                       
CREATE TABLE table_right                                                                                                                                                                                             
(                                                                                                                                                                                                                    
    `date` Date,                                                                                                                                                                                                     
    `value` Decimal(18, 10)                                                                                                                                                                                          
)                                                                                                                                                                                                                    
ENGINE = MergeTree()                                                                                                                                                                                                 
ORDER BY date

INSERT INTO table_left values(toDate('2019-10-01'), 'hello');
INSERT INTO table_right values (toDate('2019-10-01'), 1), (toDate('2029-10-01'), 2);

SET join_use_nulls = 1;

SELECT ifNull(subquery_right.alias_value, 0)
FROM table_left
FULL OUTER JOIN 
(
    SELECT
        date,
        value AS alias_value
    FROM table_right
) AS subquery_right
ON table_left.date = subquery_right.date

Received exception from server (version 21.3.1):
Code: 43. DB::Exception: Received from localhost:9000. DB::Exception: Incompatible types of arguments corresponding to two conditional branches: while executing 'FUNCTION ifNull(alias_value :: 0, 0 :: 1) -> ifNull(alias_value, 0) Decimal(18, 10) : 2'. 
```
auto & negated_null_map_data = negated_null_map->getData();
                negated_null_map_data.resize(size);
                for (size_t i = 0; i < size; ++i)
                    negated_null_map_data[i] = !null_map_data[i];
                if (isColumnNullable(*arg_then.column))
                {
                    auto arg_then_column = arg_then.column;
                    auto result_column = IColumn::mutate(std::move(arg_then_column));
                    assert_cast<ColumnNullable &>(*result_column).applyNegatedNullMap(assert_cast<const ColumnUInt8 &>(*arg_cond.column));
                    return result_column;
                }
                else
                    return ColumnNullable::create(materializeColumnIfConst(arg_then.column), std::move(negated_null_map));
            }
            else if (cond_const_col)
            {
                if (cond_const_col->getValue<UInt8>())
                    return makeNullableColumnIfNot(arg_then.column);
                else
                    return result_type->createColumn()->cloneResized(input_rows_count);
            }
            else
                throw Exception("Illegal column " + arg_cond.column->getName() + " of first argument of function " + getName()
                    + ". Must be ColumnUInt8 or ColumnConstUInt8.",
                    ErrorCodes::ILLEGAL_COLUMN);
        }
        return nullptr;
    }
public:
    String getName() const override