aboutsummaryrefslogtreecommitdiffstats
path: root/awkgram.y
diff options
context:
space:
mode:
Diffstat (limited to 'awkgram.y')
-rw-r--r--awkgram.y10
1 files changed, 10 insertions, 0 deletions
diff --git a/awkgram.y b/awkgram.y
index 41876301..d925e750 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -2610,6 +2610,16 @@ mk_program()
(void) list_merge(cp, beginfile_block);
(void) list_merge(cp, endfile_block);
+ if (outer_comment != NULL) {
+ cp = list_merge(list_create(outer_comment), cp);
+ outer_comment = NULL;
+ }
+
+ if (interblock_comment != NULL) {
+ (void) list_append(cp, interblock_comment);
+ interblock_comment = NULL;
+ }
+
goto out;
} else {