mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-19 23:19:24 +02:00
+ added validation for the base and index registers in taicpu.op_ref
git-svn-id: branches/wasm@47951 -
This commit is contained in:
parent
64a02834ff
commit
017b7903cf
@ -203,6 +203,16 @@ implementation
|
||||
inherited create(op);
|
||||
ops:=1;
|
||||
loadref(0,_op1);
|
||||
if op in [a_get_local,a_set_local,a_tee_local] then
|
||||
begin
|
||||
if (_op1.base<>NR_LOCAL_STACK_POINTER_REG) or (_op1.index<>NR_NO) then
|
||||
internalerror(2021010201);
|
||||
end
|
||||
else
|
||||
begin
|
||||
if (_op1.base<>NR_NO) or (_op1.index<>NR_NO) then
|
||||
internalerror(2021010201);
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user