Browse files

[t/spec] tests for RT #68848, complex powers wrapped in a subroutine

git-svn-id: http://svn.pugscode.org/pugs@28940 c213334d-75ef-0310-aa23-eaa082d1ae64
  • Loading branch information...
1 parent a2bbf3c commit 8acee941c2652f0ab20beff9585addfce33b39cf moritz committed Oct 28, 2009
Showing with 10 additions and 0 deletions.
  1. +10 −0 S32-num/complex.t
View
10 S32-num/complex.t
@@ -150,6 +150,16 @@ my $pi = 3.141592653589793238;
is_approx(4.unpolar($pi), -4, "4.unpolar(pi) == -4");
}
+
+# used to be RT #68848
+{
+ is_approx exp(3.0 * log(1i)), -1.83697e-16-1i,
+ 'exp(3.0 * log(1i))';
+ sub iPower($a, $b) { exp($b * log($a)) };
+ is_approx iPower(1i, 3.0), -1.83697e-16-1i, 'same as wrapped as sub';
+
+}
+
done_testing;
# vim: ft=perl6

0 comments on commit 8acee94

Please sign in to comment.