Inherited structs that don't add any field: they are not being included on the C++ _Intf.cpp file


I am trying to compile my app with the “modern” C++ compiler in RAD Studio 11.3, which uses CLANG. My app compiles fine with the Classic Borland compiler.

CLANG is quite more “picky” in some aspects, and I have had to fix some problems in my code. But there is one that depends on RemObjects: I have a structure that is being inherited from another one and, as of this moment, doesn’t add any field to it. The _Intf.h includes correctly the declaration, but there is no definition on the _Intf.cpp file, and CLANG complains that the class is not defined. I am not sure why the classic one doesn’t complain, I do think it should be defined.

I can workaround this easily just adding a dummy field, but I though of letting you know so it can be fixed on the codegen.

Actually, there are some other problems when trying to compile withe CLANG compiler. Once I have changed that struct to include a dummy field, now when linking it is complaining about some missing constructors on some of the structs. I am not sure why those structures and not others, though.

Not to mention that I had to disable the debug information for that project to be able to link, otherwise I got an “exceeded memory limit for block number cache” error.

Has anybody been able to compile/link a RemObject project with the modern C++ compiler?


can you create a simple testcase that reproduces this issue, pls?
I’ll try to review it and do changes to codegen.

you can drop email to support@ for keeping privacy.

Hello Evgeny,

I will try to do a test case that shows this. At least the lack of constructors and class definitions when inherited from some other that doesn’t add any field should be easy.

The problems with the link error will depend on the amount of code generated, so that will need a bigger RODL, and I am not sure what can you do about that, except, maybe, adding some #pragma options to disable debug info in that units, but I tried this and didn’t work, I had to disable debug info for the whole project.

Anyway, I’ll send the test case ASAP.


Hello Evgeny,

I’ve just sent by email a test case that produces at least the original issue. The other ones I haven’t been able to reproduce on the test project, but will keep on trying.