C#中的完整字符串比较规则
我在哪里可以找到C#中某种文化的确切而完整的字符串比较规则?
例子: 使用stringcomparer.invariantculture
字符串“ masse”和“maße”相等。
需要有规则列表。
也有类似的问题,例如:
不变式colliantculture and ordinal string string string和ordinal字符串比较
这解释了概念并举例说明了例子。但是我想拥有定义实际规则的来源。
Where do I find the exact and complete string comparison rules for a certain culture in C#?
Example:
With StringComparer.InvariantCulture
the strings "Masse" and "Maße" are equal.
There needs to be list of rules.
There have been similar questions, like:
Difference between InvariantCulture and Ordinal string comparison
This explains the concepts and gives examples. But I would like to have the source where the actual rules are defined.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
对于C#,这在历史上取决于C#的版本和风味以及您正在运行的操作系统的变化。
奥利维尔(Olivier)的评论是最新信息来源:行为会发生变化。
我希望基于ICU的所有平台上的C#统一将是稳定的。
ICU是由来自
For C#, this has historically varied depending on which version and flavor of C# and what OS you're running on.
Olivier's comment is an excellent current source of information: Behavior changes when comparing strings on .NET 5+.
I expect this unification of C# on all platforms based on ICU to be stable.
ICU is an API that is driven by data from the Unicode CLDR project. So the precise mappings and equivalences in your example are ultimately derived from CLDR.