sub parse-names

Documentation for sub parse-names, assembled from the following types:

class Str

From Str

(Str) routine parse-names

sub    parse-names(Str:D $names  --> Str:D)
method parse-names(Str:D $names: --> Str:D)

Takes string with comma-separated Unicode names of characters and returns a string composed of those characters. Will fail if any of the characters' names are empty or not recognized. Whitespace around character names is ignored.

say "{parse-names 'TWO HEARTS'} Perl"# OUTPUT: «I 💕 Perl␤» 
'TWO HEARTS, BUTTERFLY'.parse-names.say# OUTPUT: «💕🦋␤»