【发布时间】:2016-05-17 20:13:45
【问题描述】:
unicode-property \p{Space} 是 Perl5 扩展吗?
在 Perl5 中 Space 匹配所有空格
my $s = "one\ttwo\nthree";
$s =~ s/\p{Space}/*/g;
say $s;
# one*two*three
而在 Per6 中它可能只匹配一个简单的空格
my $s = "one\ttwo\nthree";
$s.=subst( /<:Space>/, '*', :g );
say $s;
# one two
# three
【问题讨论】:
标签: perl unicode whitespace raku