Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

[t/spec] tests for .succ/.pred on Bool

git-svn-id: http://svn.pugscode.org/pugs@26372 c213334d-75ef-0310-aa23-eaa082d1ae64
  • Loading branch information...
commit ef0570fdea7e9f3d0f640f38886ee14777c12ba4 1 parent 4bda0c5
moritz authored
Showing with 16 additions and 1 deletion.
  1. +16 −1 S03-operators/increment.t
View
17 S03-operators/increment.t
@@ -2,7 +2,7 @@ use v6;
use Test;
-plan 24;
+plan 28;
#L<S03/Autoincrement precedence>
@@ -89,3 +89,18 @@ is($moo, 0, "var was not touched");
$y += 1;
ok $y == 3.0, 'can add Int to Num with += and type constraint';
}
+
+# also a Rakudo regression
+{
+ my $x = Bool::False;
+ is ++$x, Bool::True, '++ on False works';
+ $x = Bool::False;
+ #?rakudo skip 'RT #64366'
+ is $x.succ, Bool::True, '.succ on False works';
+
+ $x = Bool::True;
+ is --$x, Bool::False, '-- on True works';
+ $x = Bool::True;
+ #?rakudo skip 'RT #64366'
+ is $x.pred, Bool::True, '.succ on False works';
+}
Please sign in to comment.
Something went wrong with that request. Please try again.