Skip to content

Commit 7f664e9

Browse files
committed
Changed maximum number of entries in multiple assignment from 8 to 16
1 parent b3378f5 commit 7f664e9

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

Changelog.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
Version 6.1.8
2+
- Changed maximum number of entries in multiple assignments from 8 to 16
23
- Fixed multiple uses of LET in BASIC programs
34
- Made sure class types are resolved when they are used as function returns
45
- Made UTF-8 the default encoding for FatFS (configurable via FF_LFN_UNICODE)

backends/asm/outasm.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ Operand *GetResultReg(int n)
430430
{
431431
static char rvalname[32];
432432
if (n < 0 || n >= MAX_TUPLE) {
433-
ERROR(NULL, "Internal error bad return value");
433+
ERROR(NULL, "Too many return values from function");
434434
return NULL;
435435
}
436436
if (!resultreg[n]) {
@@ -4659,6 +4659,10 @@ static IR *EmitMove(IRList *irl, Operand *origdst, Operand *origsrc, AST *linenu
46594659
if (IsEmptyOperand(origdst)) {
46604660
return ir;
46614661
}
4662+
if (!src) {
4663+
ERROR(linenum, "bad move operand");
4664+
return ir;
4665+
}
46624666
if (src->kind == IMM_HUB_LABEL) {
46634667
src = NewImmediatePtr(NULL, src);
46644668
}

frontends/common.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -582,7 +582,7 @@ struct modulestate {
582582
};
583583

584584
/* maximum number of items in a multiple assignment */
585-
#define MAX_TUPLE 8
585+
#define MAX_TUPLE 16
586586

587587
/* the current parser state */
588588
extern Module *current;

0 commit comments

Comments
 (0)