Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WIP! THESE COMMITS WILL BE SQUASHED
- Loading branch information
Showing
6 changed files
with
34 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
=begin pod :kind("Language") :subkind("Language") :category("reference") | ||
|
||
=TITLE NFG | ||
|
||
=SUBTITLE Normal Form Grapheme | ||
|
||
=head1 Overview | ||
|
||
All Strings in Raku are represented in Normal Form Grapheme, or C<NFG>. | ||
A grapheme is what a B<user> thinks a character is. | ||
|
||
my $str = "D\c[COMBINING DOT BELOW]"; | ||
say $str.chars; # OUTPUT: «1» | ||
say $str.uniname; # OUTPUT: «LATIN CAPITAL LETTER D WITH DOT BELOW» | ||
say $str.ord.base(16); # OUTPUT: «1E0C» | ||
say "D\c[COMBINING DOT BELOW]" eq "Ḍ"; # OUTPUT: «True» | ||
|
||
In this example, we create a string by combining two different codepoints. | ||
Raku composes this into the combined codepoint, which you can then introspect. | ||
From Raku's standpoint, there's no difference between a string assembled from | ||
the combined codepoints, or a precomposed character. | ||
|
||
=head1 What's a normalization form? - Go through the unicode ones. | ||
|
||
=head1 Related classes like Uni | ||
|
||
=end pod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters