Skip to content

Commit a4292f5

Browse files
committed
Document unimatch. Also add uniprops to the words file
1 parent 5bffa57 commit a4292f5

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

doc/Type/Cool.pod6

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -928,6 +928,20 @@ codepoints in that character.
928928
say "Ḍ̇'oh".comb>>.uninames.perl;
929929
# (("LATIN CAPITAL LETTER D WITH DOT BELOW", "COMBINING DOT ABOVE").Seq, ("APOSTROPHE",).Seq, ("LATIN SMALL LETTER O",).Seq, ("LATIN SMALL LETTER H",).Seq)
930930
931+
=head2 method unimatch
932+
933+
Defined as:
934+
sub unimatch(Str:D $str, |c)
935+
unimatch(Int:D $code, Stringy:D $pvalname, Stringy:D $propname = $pvalname)
936+
937+
Checks if the given integer codepoint or the first letter of the string given have a unicode property
938+
equal to the value you give. If you supply the Unicode property to be checked it will only return True
939+
if that property matches the given value.
940+
941+
say unimatch 'A', 'Latin' # True
942+
say unimatch 'A', 'Latin', 'Script' # True
943+
say unimatch 'A', 'Ll' #True
944+
931945
=head2 routine chop
932946
933947
Defined as:

xt/words.pws

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1085,6 +1085,7 @@ unimportable
10851085
uniname
10861086
uninames
10871087
uniprop
1088+
uniprops
10881089
unival
10891090
univals
10901091
unlesselse

0 commit comments

Comments
 (0)