]> git.vpit.fr Git - perl/modules/indirect.git/blobdiff - t/20-good.t
Handle indirect calls on blocks
[perl/modules/indirect.git] / t / 20-good.t
index 88d80603cbae021567a929cbc75fb85206526595..0f482a55cf0a3bce2d3026b11fa39457e8215261 100644 (file)
@@ -14,6 +14,7 @@ use Test::More tests => 56 * 4;
 my ($obj, $pkg, $cb, $x, @a);
 our $y;
 sub meh;
+sub try (&);
 
 {
  local $/ = "####";
@@ -129,21 +130,6 @@ $obj = $pkg->$cb( $obj  );
 ####
 $obj = $pkg->$cb(qw/foo bar baz/);
 ####
-$obj = new { $x };
-####
-$obj = new
-  {
-     $x  }
-  ();
-####
-$obj = new {
-  $x  } qq/foo/;
-####
-$obj = new
-   {
-      $x
-    }(qw/bar baz/);
-####
 meh;
 ####
 meh $_;
@@ -191,3 +177,11 @@ exec { $a[0] } @a;
 system $x $x, @a;
 ####
 system { $a[0] } @a;
+####
+try { };
+####
+try { 1; };
+####
+try { 1; 1; };
+####
+try { try { }; 1; };