Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Unbust tests after ; => , correction.
We need to be eager with these operations to ensure they take place in
the scope of the try.
  • Loading branch information
jnthn committed Apr 4, 2015
1 parent cc2c90b commit f153994
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions S29-context/die.t
Expand Up @@ -34,10 +34,10 @@ try { recurse(1) };
is($!, "Only this\n", 'die() in recursively called sub');

# die in if,map,grep etc.
is ({ try { map { die }, 1,2,3 }; 42 }()), 42, "die in map";
is ({ try { grep { die }, 1,2,3 }; 42 }()), 42, "die in grep";
is ({ try { sort { die }, 1,2,3 }; 42 }()), 42, "die in sort";
is ({ try { reduce { die }, 1,2,3 }; 42 }()), 42, "die in reduce";
is ({ try { eager map { die }, 1,2,3 }; 42 }()), 42, "die in map";
is ({ try { eager grep { die }, 1,2,3 }; 42 }()), 42, "die in grep";
is ({ try { eager sort { die }, 1,2,3 }; 42 }()), 42, "die in sort";
is ({ try { reduce { die }, 1,2,3 }; 42 }()), 42, "die in reduce";

is ({ try { for 1,2,3 { die }; 23 }; 42 }()), 42, "die in for";
is ({ try { if 1 { die } else { die } }; 42 }()), 42, "die in if";
Expand Down

0 comments on commit f153994

Please sign in to comment.