Hi!
On Wed, 28 Jul 2021, James wrote:
> It could be that .NET is using some locale based collation. Seems like a
> lot of machinery, but might do the trick
> https://pkg.go.dev/golang.org/x/[email protected]/collate
I have managed to get the .NET code used for sorting:
Files.Sort((x, y) => string.Compare(x.RelativePath, y.RelativePath,
CultureInfo.InvariantCulture,
CompareOptions.IgnoreCase));
My NET-fu is weak, but I do wonder what exactly
`CultureInfo.InvariantCulture` means in the context of sorting.
I'll do some more digging, but I suspect the only way I can match
the .NET behavior 100% is indeed x/text/collate :-/
Best,
Tobias
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/golang-nuts/YQEL3LACi1OoypUc%40skade.schwarzvogel.de.