Because of derived instance with GeneralizedNewtypeDeriving, mconcat breaks list fusion and causes extra allocations when used with Utf8Builder. Here is a way to reproduce:
foobar-<>
foobar-mappend
fuse-builder-exe: fuseThis: List did not fuse
CallStack (from HasCallStack):
error, called at ./Data/List/Fusion/Probe.hs:52:16
Because of derived instance with
GeneralizedNewtypeDeriving
,mconcat
breaks list fusion and causes extra allocations when used withUtf8Builder
. Here is a way to reproduce:fuseThis
comes fromData.List.Fusion.Probe
Code above results in:
But with the fix in this PR: