def Entries.shrink
import bend-trace-context@0.2.0.0/trace_context.bend as TraceContextimport Base
2460# One removal step (spec #1): the rightmost entry larger than 128 octets, or
2461# the rightmost entry when none is.
2462def Entries.shrink(+entries: List<&2, StateEntry>) -> List<&2, StateEntry>:
2463 Bool.pick(List<&2, StateEntry>, Entries.has_large(entries), Entries.drop_last_large(entries),
2464 Entries.drop_last(entries))