added comment sepaerator quoting
authorChristian Würdig <chriswue@ipd.info.uni-karlsruhe.de>
Fri, 17 Mar 2006 13:54:13 +0000 (13:54 +0000)
committerChristian Würdig <chriswue@ipd.info.uni-karlsruhe.de>
Fri, 17 Mar 2006 13:54:13 +0000 (13:54 +0000)
ir/be/scripts/generate_emitter.pl

index 2262bda..8c367d1 100755 (executable)
@@ -28,6 +28,8 @@ unless ($return = do $specfile) {
 }
 use strict "subs";
 
+my $comment_string_quoted = quotemeta($comment_string);
+
 my $target_c = $target_dir."/gen_".$arch."_emitter.c";
 my $target_h = $target_dir."/gen_".$arch."_emitter.h";
 
@@ -62,7 +64,7 @@ foreach my $op (keys(%nodes)) {
                        my $cnt = 0;
                        my $buf = 'cmd_buf';
 
-                       foreach $template (split(/$comment_string/, $fmt, 2)) {
+                       foreach $template (split(/$comment_string_quoted/, $fmt, 2)) {
                                my @params;
                                my $res = "";
                                $cnt++;