Skip to content

Commit 603cb75

Browse files
committed
minor edits and typo fix
1 parent 305ee67 commit 603cb75

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ name found in the *Perl Cookbook*.
8686

8787
## LICENSE
8888

89-
Artistic 2.0. See [LICENSE](https://github.com/tbrowder/Text-Utils-Raku/blob/master/LICENSE).
89+
Artistic 2.0. See that license [here](./LICENSE).
9090

9191
## COPYRIGHT
9292

lib/Text/Utils.pm6

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ multi strip-comment($line is copy, #= string of text with possible comment
100100
} # strip-comment
101101

102102
#-----------------------------------------------------------------------
103-
#| Purpose : Add commas to a mumber to separate multiples of a thousand
103+
#| Purpose : Add commas to a number to separate multiples of a thousand
104104
#| Params : An integer or number with a decimal fraction
105105
#| Returns : The input number with commas added, e.g.,
106106
#| 1234.56 => 1,234.56
@@ -109,8 +109,8 @@ sub commify($num) is export(:commify) {
109109
say "DEBUG: input '$num'" if $DEBUG;
110110
my $text = $num.flip;
111111
say "DEBUG: input flipped '$text'" if $DEBUG;
112-
#$text =~ s:g/ (\d\d\d)(?=\d)(?!\d*\.)/$0,/; # how to do in Perl 6?
113-
112+
#$text =~ s:g/ (\d\d\d)(?=\d)(?!\d*\.)/$0,/; # Perl
113+
# in Raku:
114114
$text ~~ s:g/ (\d\d\d) <?before \d> <!before \d*\.> /$0,/;
115115
116116
# don't forget to flip back to the original

0 commit comments

Comments
 (0)