def ends_with
import bend-kit-bytes@0.3.3.0/bytes.bend as Bytesimport Base
489# Does b end with suffix (a byte string)?
490def ends_with(b: Bytes, +suffix: String) -> Bytes & Bool:
491 Bytes{+len, buf} = b
492 +m = count(suffix, 0)
493 at.if(U32.is_le(m, len), len, buf, suffix, (len - m : U32))
Uses (9)
Used by (0)
No other definition uses this definition.