///|
#borrow(left, right)
extern "c" fn moonbit_glib_utf8_collate(left : Bytes, right : Bytes) -> Int = "moonbit_glib_utf8_collate"

///|
/// Compares two UTF-8 strings using the current locale's collation rules.
pub fn utf8_collate(left : String, right : String) -> Int {
  moonbit_glib_utf8_collate(
    @encoding/utf8.encode(left),
    @encoding/utf8.encode(right),
  )
}