I notice that unlike EIP-196, EIP-2537 does not allow truncated / virtually padded with zeros.
Encoding
Field elements and scalars are encoded as 32 byte big-endian numbers. Curve points are encoded as two field elements
(x, y), where the point at infinity is encoded as(0, 0).Tuples of objects are encoded as their concatenation.
For both precompiled contracts, if the input is shorter than expected, it is assumed to be virtually padded with zeros at the end (i.e. compatible with the semantics of the
CALLDATALOADopcode). If the input is longer than expected, surplus bytes at the end are ignored.The length of the returned data is always as specified (i.e. it is not “unpadded”).
Is this intentional? I wonder if we can make a retroactive EIP to enshrine the same for EIP-196.