Skip to content

Unicode version 2.2.0

Latest

Choose a tag to compare

@kipcole9 kipcole9 released this 19 Sep 23:55
· 1 commit to main since this release

This release makes every property value the Unicode Character Database declares resolvable, including the values a data file supplies only through an @missing annotation.

Enhancements

  • Resolves the default value of fifteen further properties, so \p{jt=U}, \p{bpt=None}, \p{sc=Unknown}, \p{age=NA} and their companions now answer. Every property's values together account for all 1,114,112 codepoints, where before only five did.

  • Applies the range-specific defaults BidiClass.txt declares, so an unassigned codepoint in a right-to-left block resolves as R or AL rather than L.

  • Resolves Joining_Group values from any spelling, including the Crown_Ain form PropertyValueAliases.txt uses. 73 of the 116 values previously resolved from neither spelling.

  • Resolves binary property aliases that contain a separator, such as Bidi_M, Gr_Base and Pat_Syn, which the lookup normalised but the alias table did not.

  • Documents Unicode.fetch_property/1 and Unicode.get_property/1, which resolve a property named at runtime to the module that serves it. Both were public but carried @doc false, so the lookup that unicode_set evaluates set expressions with was absent from the documentation.

  • Adds an introduction guide covering the shape of the API: the three ways to reach a property, naming property values, character names, script extensions and the guards. Its examples run as doctests.

  • Loads NameAliases.txt, so Unicode.CharacterName.to_codepoint/2 resolves the names of the control characters, which have no Name property, along with abbreviations such as LF and the corrections for characters whose published name contains an error. Unicode.CharacterName.aliases/1 returns a codepoint's aliases with their types.

Bug fixes

  • Unicode.EastAsianWidth.east_asian_width_category/1 returns the UCD default :n, rather than :other which is not a value of the property, for codepoints EastAsianWidth.txt omits.

Notes

  • known_*/0 and count/1 include the default value for the affected properties, so those lists and counts are larger than in 2.1.0.