How can I identify and get rid of unused units in the “uses clause” in Delphi 7?

后端 未结 7 701
北海茫月
北海茫月 2020-12-03 14:44

This should reduce the executable size quite a bit in some of my very large projects. I am sure there would be other benefits too.

EDIT: Is there perhaps a utility t

7条回答
  •  Happy的楠姐
    2020-12-03 15:07

    If your code can be compiled with Free Pascal, the Free Pascal compiler also will emit hints about unused units in your code.

    See also this SO entry with additional information about possible problems, like RTTI based methods:

    https://stackoverflow.com/questions/605977/tools-to-detect-dead-code-in-delphi2007-or-above/

提交回复
热议问题