From 1d6b7e905031a3b83d8cd534eb6ec00bd11dba2e Mon Sep 17 00:00:00 2001 From: pierre Date: Tue, 6 Jun 2000 20:24:07 +0000 Subject: [PATCH] Generate a warning if function result is a pointer and result^:=x; is used --- compiler/tree.pas | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/compiler/tree.pas b/compiler/tree.pas index 8cbbb8d12d..da12734e7c 100644 --- a/compiler/tree.pas +++ b/compiler/tree.pas @@ -1802,7 +1802,7 @@ unit tree; if p^.is_first_funcret then pprocinfo(p^.funcretprocinfo)^.funcret_state:=vs_assigned; end; - vecn,typeconvn,subscriptn,derefn: + vecn,typeconvn,subscriptn{,derefn}: set_funcret_is_valid(p^.left); end; end; @@ -2121,7 +2121,10 @@ unit tree; end. { $Log$ - Revision 1.120 2000-05-17 17:10:06 peter + Revision 1.121 2000-06-06 20:24:07 pierre + Generate a warning if function result is a pointer and result^:=x; is used + + Revision 1.120 2000/05/17 17:10:06 peter * add support for loading of typed const strings with resourcestrings, made the loading also a bit more generic @@ -2242,4 +2245,4 @@ end. a same register is freed twice (happens in several part of current compiler like addn for strings and sets) -} +} \ No newline at end of file