Lars Fosdal 1792 Posted August 23, 2019 [dcc32 Warning] W1029 Duplicate constructor 'MyClassName.ConstructorName' with identical parameters will be inacessible from C++ {$WARN DUPLICATE_CTOR_DTOR OFF} does not seem to have any effect in Delphi 10.3.1 I know I can add an extra dummy parameter to change the signature - but shouldn't that $WARN thing have worked too? Share this post Link to post
Stefan Glienke 2002 Posted August 23, 2019 (edited) Assuming that you don't need to use that code from C++Builder just turn off header generation. Edited August 23, 2019 by Stefan Glienke 1 Share this post Link to post
Uwe Raabe 2057 Posted August 23, 2019 It may help to place that directive in the project file instead of the unit with the class declaration. 1 1 Share this post Link to post
ByteJuggler 45 Posted August 23, 2019 1 hour ago, Uwe Raabe said: It may help to place that directive in the project file instead of the unit with the class declaration. Yes, IIRC you're correct. We had to (IIRC) use the .dproj file switch because for whatever reason (bug?) the compiler ignores the compiler directive but does respect the .dproj flag. (To add, in our case the "C++ output file generation" was also already off, however the compiler still emits/emitted this warning from one of the Synopse modules e.g. SynCommons.pas: "'ESynException.CreateLastOSError' with identical parameters will be inaccessible from C++" (and checking the module was being recompiled from scratch.) The only way that worked was the .dproj flag. 1 Share this post Link to post
Attila Kovacs 629 Posted December 17, 2020 Project Options -> Delphi Compiler -> Hints and Warnings -> Output warnings -> "Duplicate constructor/destructor with identical parameters will be inacessible from C++" -> False did the trick. (Note the typo in the IDE) 1 Share this post Link to post
Guest Posted December 22, 2020 Wow! +1 to Lars for asking the question that i should have asked for ages now. +1 to ByteJuggler for presenting the exact "problem" i have and the solution. I love this forum. Share this post Link to post