What is a Delphi DCU file?

后端 未结 3 542
庸人自扰
庸人自扰 2021-01-17 08:39

What is a Delphi DCU file?

I believe it stands for \"Delphi Compiled Unit\". Am I correct in assuming it contains object code, and therefore corresponds to an \".o\"

3条回答
  •  孤城傲影
    2021-01-17 09:03

    A Delphi Compiled Unit contains object code, and pre-compiled headers, and is therefore somewhat comparable to both an obj file and a .pch / .gch file.

    The 'interface' section of a Delphi source file corresponds to the header, and the 'implementation' section creates the object code.

    Pre-compiled header files may significantly reduce compilation and link time. The DCU header section provides link information to other referenced units, that does not have to be re-discovered.

    In the Delphi / Turbo Pascal environment, pre-compiled headers support strict type checking, which would have required source-code referencing if an Object file format like .coff or .obj had been used. (In C++, name mangling provides a similar but less complete function).

提交回复
热议问题