* Fix from Mattias Gaertner for System.Delete() use analyses.

git-svn-id: trunk@35703 -
This commit is contained in:
michael 2017-04-01 15:59:57 +00:00
parent 945b0aa98b
commit 9e39442dbc
2 changed files with 4 additions and 0 deletions

View File

@ -607,6 +607,8 @@ begin
UseExpr(TPasExpr(El))
else if C=TPasEnumValue then
MarkElementAsUsed(El)
else if C.InheritsFrom(TPasModule) then
// e.g. unitname.identifier -> the module is used by the identifier
else
RaiseNotSupported(20170307090947,El);
end;

View File

@ -1134,8 +1134,10 @@ begin
StartProgram(false);
Add('var {#a_notused}a: longint;');
Add('var {#b_used}b: longint;');
Add('var {#c_used}c: longint;');
Add('begin');
Add(' b:=2;');
Add(' afile.c:=3;');
AnalyzeWholeProgram;
end;