Author: infinoid
Date: Fri Jan 2 22:13:43 2009
New Revision: 34855
Modified:
branches/assert_args/tools/build/headerizer.pl
Log:
[headerizer] Fix for generating asserts for "array[]" arguments.
Modified: branches/assert_args/tools/build/headerizer.pl
==============================================================================
--- branches/assert_args/tools/build/headerizer.pl (original)
+++ branches/assert_args/tools/build/headerizer.pl Fri Jan 2 22:13:43 2009
@@ -310,6 +310,8 @@
# try to isolate the variable's name;
# strip off everything before the final space or asterisk.
$var =~ s[.+[* ]([^* ]+)$][$1];
+ # strip off a trailing "[]", if any.
+ $var =~ s/\[\]$//;
}
push( @asserts, "PARROT_ASSERT_ARG($var)" );
}