diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2016-11-08 22:18:41 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2016-11-08 22:18:41 +0900 |
| commit | 1142cf20370362ab2b974b235e7606246245ce23 (patch) | |
| tree | 3bee407447f7f0d505dd8dcb8432a4d94bb74365 | |
| parent | 6c299aae67e2e0f13a470b855298bc1efb43387a (diff) | |
| download | mruby-1142cf20370362ab2b974b235e7606246245ce23.tar.gz mruby-1142cf20370362ab2b974b235e7606246245ce23.zip | |
fixed a bug with [] in RHS of multiple assignments; fix #3236
| -rw-r--r-- | mrbgems/mruby-compiler/core/codegen.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mrbgems/mruby-compiler/core/codegen.c b/mrbgems/mruby-compiler/core/codegen.c index efdd77888..c898acddc 100644 --- a/mrbgems/mruby-compiler/core/codegen.c +++ b/mrbgems/mruby-compiler/core/codegen.c @@ -1645,7 +1645,7 @@ codegen(codegen_scope *s, node *tree, int val) node *t = tree->cdr, *p; int rhs = cursp(); - if ((intptr_t)t->car == NODE_ARRAY && nosplat(t->cdr)) { + if ((intptr_t)t->car == NODE_ARRAY && t->cdr && nosplat(t->cdr)) { /* fixed rhs */ t = t->cdr; while (t) { |
