Under terms of
MDEV-274 we added the INET6 data type, to store IPv6 addresses as 16-byte binary strings.
Let's also add a data type to store IPv4 addresses, as 4-byte binary strings.
The new data type name will be INET4.
INET4 should be implemented in the same directory with INET6: plugin/type_inet/, so INET4 and INET6 "know" each other:
- They should support explicit CAST between each other
- INET6 should be a super type for INET4.
will implicitly cast inet4_expr to INET6 and return a result of the INET6 data type.
will implicitly cast inet4_expr to INET6, then compare in INET6 format.
- They should possibly support implicit CAST between each other in some other cases. The exact list is to be defined.