ClickHouse server version 20.8.9 revision 54438

Let's imagine some simple table structure:

```
CREATE TABLE users (
    `user_id` Int32
)
```

Modulo operator on **Int32** field with **150** argument returns negative result. This could have happened due to wrong type casting - result should be casted to **Int16** or **UInt8** instead of **Int8**.

```
SELECT 
    user_id % 150, 
    441746 % 150,
    toTypeName(user_id % 150),
    toTypeName(441746 % 150)
FROM users 
WHERE user_id = 441746
LIMIT 1
```

```
┌─modulo(user_id, 150)─┬─modulo(441746, 150)─┬─toTypeName(modulo(user_id, 150))─┬─toTypeName(modulo(441746, 150))─┐
│                -110  │                 146 │ Int8                             │ UInt8                           │
└──────────────────────┴─────────────────────┴──────────────────────────────────┴─────────────────────────────────┘
```
template <typename A, typename B> struct ResultOfSubtraction
{
    using Type = typename Construct<
        true,
        std::is_floating_point_v<A> || std::is_floating_point_v<B>,
        nextSize(max(sizeof(A), sizeof(B)))>::Type;
};
/** When dividing, you always get a floating-point number.
    */
template <typename A, typename B> struct ResultOfFloatingPointDivision
{
    using Type = Float64;
};
/** For integer division, we get a number with the same number of bits as in divisible.
    */
template <typename A, typename B> struct ResultOfIntegerDivision
{
    using Type = typename Construct<
        is_signed_v<A> || is_signed_v<B>,
        false,
        sizeof(A)>::Type;
};
/** Division with remainder you get a number with the same number of bits as in divisor.
    */
template <typename A, typename B> struct ResultOfModulo
{
    using Type0 = typename Construct<is_signed_v<A> || is_signed_v<B>, false, sizeof(B)>::Type;
    using Type = std::conditional_t<std::is_floating_point_v<A> || std::is_floating_point_v<B>, Float64, Type0>;
};
template <typename A> struct ResultOfNegate