Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

remove sigils from | and \

  • Loading branch information...
commit e6ba01a50ce7970f9d3f5e926be166df1e78abe8 1 parent 5397065
@TimToady TimToady authored
View
2  S02-types/anon_block.t
@@ -143,7 +143,7 @@ isnt((sub { -> { 3 } }).(), 3, 'as are pointies');
#?niecza skip 'No candidates for dispatch to mone'
#?pugs skip 'parsefail'
{
- proto mone(|$) { * }
+ proto mone(|) { * }
multi mone { 'one' }
is &mone(), 'one', 'check that mutli is callable via &';
is { &^x() }.( &mone ), 'one',
View
4 S02-types/capture.t
@@ -54,7 +54,7 @@ plan 21;
# L<S06/Argument list binding/single scalar parameter marked>
{
sub bar6 ($a, $b, $c) { "$a!$b!$c" }
- sub foo6 (|$capture) { bar6(|$capture) }
+ sub foo6 (|capture) { bar6(|capture) }
#?pugs todo "feature"
is foo6(1,2,3), "1!2!3",
@@ -75,7 +75,7 @@ plan 21;
# Arglists are first-class objects
{
my $capture;
- sub foo7 (|$args) { $capture = $args }
+ sub foo7 (|args) { $capture = args }
lives_ok { foo7(1,2,3,4) }, "captures are first-class objects (1)";
#?pugs todo "feature"
View
2  S02-types/sigils-and-types.t
@@ -60,7 +60,7 @@ ok &foo.does(Callable), 'a Sub does Callable';
method meth {}
ok &meth.does(Callable), 'a Method does Callable';
}
-proto mul(|$) {*}
+proto mul(|) {*}
multi mul {}
ok &mul.does(Callable), 'a multi does Callable';
proto pro {}
View
2  S06-multi/syntax.t
@@ -161,7 +161,7 @@ ok(~&foo ~~ /foo/, 'a multi stringifies sensibly');
}
multi with_cap($a) { $a }
-multi with_cap($a,$b,|$cap) { return with_cap($a + $b, |$cap) }
+multi with_cap($a,$b,|cap) { return with_cap($a + $b, |cap) }
#?pugs skip 'with_cap not found'
is with_cap(1,2,3,4,5,6), 21, 'captures in multi sigs work';
View
12 S06-signature/introspection.t
@@ -114,11 +114,11 @@ sub j(*@i) {
#?niecza skip "Action method fakesignature not yet implemented"
{
my $x;
- ok :(|$x).params[0].capture, 'prefix | makes .capture true';
- ok :(|$x).perl ~~ / '|' /, 'prefix | appears in .perl output';
+ ok :(|x).params[0].capture, 'prefix | makes .capture true';
+ ok :(|x).perl ~~ / '|' /, 'prefix | appears in .perl output';
- ok :(\$x).params[0].parcel, 'prefix \\ makes .parcel true';
- ok :(\$x).perl ~~ / '\\' /, 'prefix \\ appears in .perl output';
+ ok :(\x).params[0].parcel, 'prefix \\ makes .parcel true';
+ ok :(\x).perl ~~ / '\\' /, 'prefix \\ appears in .perl output';
}
# RT #69492
@@ -130,8 +130,8 @@ sub j(*@i) {
# Capture param introspection
{
- sub xyz(|$c) {};
- is &xyz.signature.params[0].name, '$c' , '.name of |$c is "$c"';
+ sub xyz(|c) {};
+ is &xyz.signature.params[0].name, 'c' , '.name of |c is "c"';
#?niecza todo "Does this test make sense?"
is &xyz.signature.params[0].positional, False, '.positional on Capture param is False';
is &xyz.signature.params[0].capture, True , '.capture on Capture param is True';
View
2  S12-methods/multi.t
@@ -51,7 +51,7 @@ role R2 {
}
eval_dies_ok 'class X does R1 does R2 { }', 'sanity: get composition conflict error';
class C does R1 does R2 {
- proto method foo(|$) { * }
+ proto method foo(|) { * }
}
my $obj = C.new;
#?rakudo 2 skip 'proto does not promote to multi'
View
2  S13-overloading/typecasting-mixed.t
@@ -8,7 +8,7 @@ plan 14;
{
class TypeCastMixed {
- method &.( |$capture ) {return 'pretending to be a sub'} #OK not used
+ method &.( |capture ) {return 'pretending to be a sub'} #OK not used
method postcircumfix:<[ ]> (**@slice) {return 'pretending to be an array'} #OK not used
method %.{ **@slice } {return 'pretending to be a hash'} #OK not used
}
View
2  S14-traits/routines.t
@@ -55,7 +55,7 @@ plan 12;
# RT 112664
{
multi trait_mod:<is>($m, :$a!) {
- multi y(|$) { my $x = $m }
+ multi y(|) { my $x = $m }
$m.wrap(&y)
}
sub rt112664 is a {}
Please sign in to comment.
Something went wrong with that request. Please try again.