usefluent_langneg::NegotiationStrategy;useicu_locid::LanguageIdentifier;modfetch;pubmodunix;pubfnmatch_locales(available:&[LanguageIdentifier],
default:&LanguageIdentifier,
)->Vec<LanguageIdentifier>{// TODO: requesting locales should have platform-specific logic
let requested =unix::get_locales(fetch::unix::LocaleCategory::Messages);let supported =fluent_langneg::negotiate_languages(&requested,&available,Some(&default),NegotiationStrategy::Matching,);// TODO: this is wasteful but avoids dealing with lifetimes for now
supported.into_iter().cloned().collect()}