We have a C ++ Builder XE project (VCL Forms application), in which there are several dozen forms and units. Whenever a file belonging to a project is added, deleted, or renamed, the IDE must do two things:
- A USEFORM macro call is added or modified in the project source file (ProjectName.cpp) if the affected element is a form or frame
- Added or modified CppCompile element in the project file (ProjectName.cbproj)
However, instead of making the necessary changes, the IDE moves some of the existing USEFORM and CppCompile entries, even if they are not subject to change. If I add Unit (cpp and header file), USEFORMs are shuffled, even if it does not require any changes to the Source Project, only for the cbproj file.
I do not see a specific template about how the new order is formed. If I edit or rename one unit, about half of the USEFORMs seem to change position and only a couple or none of the CppCompile entries. If changing a copy of a project is done on two different machines, most of the changes seem to be similar, but not all. This means that reordering is not random.
Behavior causes problems when using Subversion to merge changes, because it forces you to manually resolve conflicts caused by the changing order.
So the question is: what can cause the above behavior and how to get rid of it?
Samuli hynönen
source share