(*fieldElement).Bytes() uses the inlining trick to punt its allocation up to the caller. (*Point).Bytes calls (*fieldElement).Bytes(), but (*Point).Bytes is itself too large to be inlined, so the caller of (*Point).Bytes incurs a heap allocation. This PR outlines (*Point).bytes, allowing the caller to (potentially) avoid the allocation.
(*fieldElement).Bytes()
uses the inlining trick to punt its allocation up to the caller.(*Point).Bytes
calls(*fieldElement).Bytes()
, but(*Point).Bytes
is itself too large to be inlined, so the caller of(*Point).Bytes
incurs a heap allocation. This PR outlines(*Point).bytes
, allowing the caller to (potentially) avoid the allocation.