[svn:parrot] r42569 - trunk/t/compilers/imcc/syn
coke at svn.parrot.org
coke at svn.parrot.org
Wed Nov 18 19:31:55 UTC 2009
Author: coke
Date: Wed Nov 18 19:31:54 2009
New Revision: 42569
URL: https://trac.parrot.org/parrot/changeset/42569
Log:
Add test for a bug discovered by Tene++
Modified:
trunk/t/compilers/imcc/syn/regressions.t
Modified: trunk/t/compilers/imcc/syn/regressions.t
==============================================================================
--- trunk/t/compilers/imcc/syn/regressions.t Wed Nov 18 19:29:57 2009 (r42568)
+++ trunk/t/compilers/imcc/syn/regressions.t Wed Nov 18 19:31:54 2009 (r42569)
@@ -6,7 +6,7 @@
use warnings;
use lib qw( . lib ../lib ../../lib );
use Test::More;
-use Parrot::Test tests => 17;
+use Parrot::Test tests => 20;
pir_error_output_like( <<'CODE', <<'OUT', 'invalid get_results syntax');
.sub main :main
@@ -235,8 +235,29 @@
CODE
OUT
+# This test probably belongs in subflags.t
+# The test inspired by TT #744, even though it presents differently.
+{
+ my @types = qw/string num pmc/;
+ foreach my $invalid_type (@types) {
+
+ pir_error_output_like( <<"CODE", <<'OUT', 'opt_flag must be an int.', todo => 'broken');
+
+.sub bar
+ .param pmc foo :optional
+ .param $invalid_type joe :opt_flag
+ say joe
+.end
+.sub main :main
+bar()
+.end
+CODE
+/:opt_flag parameter must be of type 'int'/
+OUT
+ }
+}
# Local Variables:
# mode: cperl
More information about the parrot-commits
mailing list