Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
tests for RT #78234, sub declaration inside a "given"
  • Loading branch information
moritz committed Oct 25, 2011
1 parent 87785c0 commit 148cafa
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion S04-statements/given.t
Expand Up @@ -2,7 +2,7 @@ use v6;

use Test;

plan 49;
plan 51;

=begin pod
Expand Down Expand Up @@ -305,4 +305,8 @@ Tests the given block, as defined in L<S04/"Switch statements">
is $tracker, 2, 'statement-modifying when';
}

# RT #78234
eval_lives_ok 'given 3 { sub a() { } }', 'can define a sub inside a given';
eval_lives_ok 'sub a() { } given 3', 'can define a sub inside a statement-modifying given';

# vim: ft=perl6

0 comments on commit 148cafa

Please sign in to comment.