Reproduces on master.

```
SELECT toDateTime64('2021-03-22', 3, 'Asia/Tehran')

Query id: 26f7c373-f473-4209-8976-6ada79a8627f

┌─toDateTime64('2021-03-22', 3, 'Asia/Tehran')─┐
│                      2157-04-28 06:28:16.000 │
└──────────────────────────────────────────────┘
```
{
        return lut[makeLUTIndex(year, month, day_of_month)].date;
    }
    /** Does not accept daylight saving time as argument: in case of ambiguity, it choose greater timestamp.
      */
    inline Time makeDateTime(Int16 year, UInt8 month, UInt8 day_of_month, UInt8 hour, UInt8 minute, UInt8 second) const
    {
        size_t index = makeLUTIndex(year, month, day_of_month);
        UInt32 time_offset = hour * 3600 + minute * 60 + second;
        if (time_offset >= lut[index].time_at_offset_change())
            time_offset -= lut[index].amount_of_offset_change();
        return lut[index].date + time_offset;
    }
    template <typename DateOrTime>
    inline const Values & getValues(DateOrTime v) const { return lut[toLUTIndex(v)]; }
    template <typename DateOrTime>
    inline UInt32 toNumYYYYMM(DateOrTime v) const
    {
        const Values & values = getValues(v);
        return values.year * 100 + values.month;
    }
    template <typename DateOrTime>
    inline UInt32 toNumYYYYMMDD(DateOrTime v) const
    {
        const Values & values = getValues(v);
        return values.year * 10000 + values.month * 100 + values.day_of_month;
    }
    inline Time YYYYMMDDToDate(UInt32 num) const