shithub: furgit

ref: df1f2fb3daa1acd25c88510f259d5535fb482126
dir: /object/id/objectid_compare.go/

View raw version
package objectid

import "bytes"

// Compare lexicographically compares two object IDs by their canonical byte
// representation.
func Compare(left, right ObjectID) int {
	return bytes.Compare(left.RawBytes(), right.RawBytes())
}