HaraldurH 0 Posted October 14, 2020 Me and my co-workers have been using Delphi for about 20 years - for the same project, that has grown bigger and bigger each year, containing around 800 forms and frames. Yes, it's big. 2-3 years ago we noticed that compiling this project by opening some of these forms; change them and then press F9 for compile and then running - did not work: The process of compile did not link. It went into an endless loop, compiling form after form; frame after frame; many of the forms again and again. The only way now is to build the whole project and then it links. Some of the forms work ok: We can open them, make a little change and then F9 takes us through the compile/link process and the application starts. The worst thing is that we don't know when exactly this started.. and we can't resolve this by going back in our source-history ( subversion ) and find out how/where we created this loop-of-uses-clause or what ever. Have you any ide how to find a solution? When we build our project we notice that Delphi compiles some forms/frames two or three times - so that is probably normal, but to get stuck in this process is not: we see the names of some forms appear again and again in this window ( included in post ). kind regards, Haraldur Share this post Link to post
Kryvich 165 Posted October 14, 2020 Interesting... Perhaps you got cyclic unit relations? You can check it with Unit Dependency Analyzer for ex. Share this post Link to post
Guest Posted October 14, 2020 I faced this many times in old projects and it does happen with old Delphi versions more often than newer ones. I don't have one thing to trigger this, but few things to check and hope to be one of them But first delete/remove all the DCU then trigger the endless loop, within those DCU is the culprit and it is not in the file that IDE is froze on. After building and cause the endless loop, you will have a list of DCU that one of them triggering this, so check for the following: 1) Do you have function/procedure with same exact name found in the system.pas (Delphi default) ? ( this is the most often) 2) While (1) might not be a problem on its own, but combine that with "inline", and you have chance to trigger the endless loop, to check disable any inline in the units that compiled before the freeze to verify. 3) Do you have many overloads with inline ? 4) From the unit the IDE get stuck on, split and isolate code parts, and if you can move parts into new units, until pinpoint one call that is making the IDE, and yes the code that trigger the endless loop, might not cause problem from different unit, but you will be able to understand how and why this is happeing, and it is fixable. Hope that help you, and good luck. Share this post Link to post
Darian Miller 361 Posted October 14, 2020 Which version of Delphi? Sometimes corrupt .FRM files cause an issue. Test in a new directory and convert all To / From text to binary. Share this post Link to post
Anders Melander 1782 Posted October 14, 2020 Try building with MSBuild (Project Options, Building, Delphi Compiler, Use MSBuild externally to compile). My current client have several projects that fail during compile with internal errors unless we use MSBuild. 1 hour ago, Darian Miller said: Sometimes corrupt .FRM files cause an issue. Wouldn't that be a linker issue then. This looks like a compiler issue. Share this post Link to post