summaryrefslogtreecommitdiffhomepage
path: root/mrbgems/mruby-compiler/core/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'mrbgems/mruby-compiler/core/parse.y')
-rw-r--r--mrbgems/mruby-compiler/core/parse.y12
1 files changed, 12 insertions, 0 deletions
diff --git a/mrbgems/mruby-compiler/core/parse.y b/mrbgems/mruby-compiler/core/parse.y
index d71e90176..637b04749 100644
--- a/mrbgems/mruby-compiler/core/parse.y
+++ b/mrbgems/mruby-compiler/core/parse.y
@@ -3326,6 +3326,9 @@ string_fragment : tCHAR
if (intn($3->cdr->cdr) > 0) {
n = push(n, $3);
}
+ else {
+ cons_free($3);
+ }
$$ = new_dstr(p, n);
}
;
@@ -3372,6 +3375,9 @@ xstring : tXSTRING_BEG tXSTRING
if (intn($3->cdr->cdr) > 0) {
n = push(n, $3);
}
+ else {
+ cons_free($3);
+ }
$$ = new_dxstr(p, n);
}
;
@@ -3439,6 +3445,9 @@ words : tWORDS_BEG tSTRING
if (intn($3->cdr->cdr) > 0) {
n = push(n, $3);
}
+ else {
+ cons_free($3);
+ }
$$ = new_words(p, n);
}
;
@@ -3456,6 +3465,9 @@ symbol : basic_symbol
if (intn($4->cdr->cdr) > 0) {
n = push(n, $4);
}
+ else {
+ cons_free($4);
+ }
$$ = new_dsym(p, new_dstr(p, n));
}
;