History

arm-asm: Raise error if user tries to use a shift instruction with an immediate source operand

Danny Milosavljevic committed 5 years ago

Commit 104037a1 parent 1ed4b6b1 file · +2 −1Browse files

Unified · Split

arm-asm.c+2−1
@@ -865,7 +865,8 @@ static void asm_shift_opcode(TCCState *s1, int token) · 864 unmodified lines
865865 case OP_IM8:
866866 operands |= ENCODE_IMMEDIATE_FLAG;
867867 operands |= ops[1].e.v;
868− break;
868+ tcc_error("Using an immediate value as the source operand is not possible with '%s' instruction on ARM", get_tok_str(token, NULL));
869+ return;
869870 }
870871
871872 switch (ops[2].type) {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t