```
SELECT
    CAST(([2, 1, 1023], ['', '']), 'Map(UInt8, String)') AS map,
    map[10]
```

Triggers `Assertion 'n < size()' failed` in `DB::ColumnString::operator[](unsigned long)`
https://clickhouse-test-reports.s3.yandex.net/18481/64c4ade5b0e0c9a13d6c2475431daf431fc97554/fuzzer/fuzzer.log

Introduced here: #17829
First found here: #18481
{
        ColumnPtr result_column;
        if constexpr (to_decimal)
            result_column = executeInternal<ToDataType>(arguments, result_type, input_rows_count,
                assert_cast<const ToDataType &>(*removeNullable(result_type)).getScale());
        else
        {
            if (isDateTime64<Name, ToDataType>(arguments))
            {
                UInt64 scale = to_datetime64 ? DataTypeDateTime64::default_scale : 0;
                if (arguments.size() > 1)
                    scale = extractToDecimalScale(arguments[1]);
                if (scale == 0)
                    result_column = executeInternal<DataTypeDateTime>(arguments, result_type, input_rows_count);
                else
                {
                    result_column = executeInternal<DataTypeDateTime64>(arguments, result_type, input_rows_count, static_cast<UInt32>(scale));
                }
            }
            else
            {
                result_column = executeInternal<ToDataType>(arguments, result_type, input_rows_count);