From da6d9cf3f3773388f51b7bfe5fd35825360c0d79 Mon Sep 17 00:00:00 2001 From: Jonas Maebe Date: Fri, 16 Aug 2013 10:10:38 +0000 Subject: [PATCH] * give an internalerror when we try to change the type of an asmsymbol from anything but none (= undefined) to local git-svn-id: trunk@25266 - --- compiler/aasmtai.pas | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/compiler/aasmtai.pas b/compiler/aasmtai.pas index d9bc5c2d9a..51f4f7b8d5 100644 --- a/compiler/aasmtai.pas +++ b/compiler/aasmtai.pas @@ -1288,6 +1288,10 @@ implementation typ:=ait_symbol; sym:=_sym; size:=siz; + { don't redefine global/external symbols as local, as code to access + such symbols is different on some platforms } + if not(sym.bind in [AB_NONE,AB_LOCAL]) then + internalerror(2013081601); sym.bind:=AB_LOCAL; is_global:=false; end;