Re: [twsocket] BDS2006 & C++Personality = ERROR
What is the delphi equivalent of the below code in C++? in worker code #include ... in OverbyteIcsTypes.h, #include // should be inserted in the worker code so that it would recognize ::HWND #ifdef BCB #define HWND ::HWND #else .. #endif ... I think this is the cure for the problem. Regards, SZ - Original Message - From: "Fastream Technologies" <[EMAIL PROTECTED]> To: "ICS support mailing" Sent: Tuesday, March 14, 2006 9:01 AM Subject: Re: [twsocket] BDS2006 & C++Personality = ERROR > Ok. So we had the BCB not see the definition of new HWND. How do we make > it > work with, HWND where it expects Window.HWND? Is there a #define thing > similar to C++? Even if this exists, since each delphi unit is a module, > we > would need to re-add the unit "windows" to "uses" of each unit that uses > HWND, right? > > Regards, > > SZ > > - Original Message - > From: "Francois PIETTE" <[EMAIL PROTECTED]> > To: "ICS support mailing" > Sent: Monday, March 13, 2006 10:09 PM > Subject: Re: [twsocket] BDS2006 & C++Personality = ERROR > > >>> There is no notion of real "module" in C++. Namespaces are invented to >>> prevent name clashes for this purpose. You can have HWND and >>> Overbyteics:HWND at the same scope UNLESS you define, >>> >>> using namespace Overbyteics; >>> >>> which makes the "::" = "Overbyteics" and which is the case with >>> Overbyteics. >>> It is like adding a path to Delphi/BCB. There cannot be same named >>> components in the same project! What Francois should agree to do is to >>> rename all of the HWND's in the ICS code with Overbyteics::HWND (or >>> perhaps >>> rename the namespace name to ObICS for the sake of compacting), IMO. >> >> He think this is C++ code. It isn't. It is Delphi code. >> Instead, try conditionally compile the offending types redefinition in >> OverbyteIcsTypes.pas so that BCB doesn't see them. >> >> -- >> [EMAIL PROTECTED] >> http://www.overbyte.be >> >> -- >> To unsubscribe or change your settings for TWSocket mailing list >> please goto http://www.elists.org/mailman/listinfo/twsocket >> Visit our website at http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://www.elists.org/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] BDS2006 & C++Personality = ERROR
Hello Francois, > Date: Mon, 13 Mar 2006 19:52:28 +0100 > From: "Francois PIETTE" <[EMAIL PROTECTED]> > Subject: Re: [twsocket] BDS2006 & C++Personality = ERROR > To: "ICS support mailing" > Message-ID: <[EMAIL PROTECTED]> > Content-Type: text/plain; format=flowed; charset="iso-8859-1"; > reply-type=original > > Use ICS V5 BETA with BDS2006/C++. > V6 has not been validated yet with BDS2006/C++. > > you're right! I've just downloaded, installed, compiled the ICS V5 beta, and everthing at fist look "seems to be fine". It's my fault: but I wasn't able to find any info regarding the not-validation phase for the V6 to BDS2006/C++... >> Ambiguity between 'HWND' and >> 'Overbyteicstypes::HWND' >> Any ideas? >> > > I think some conditional compilation is needed to solve this problem. Not > sure. I had no time to dig into this problem yet. Of course you are welcome > to solve it. > > > [EMAIL PROTECTED] > http://www.overbyte.be > > Now I'm dealing with the porting of ALL the BCB6 apps I've made into BDS2006/C++. At the end of this phase, I'll try to have a look to this problem. Thanks for your support, and also to SZ. Luca Centimeri -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] BDS2006 & C++Personality = ERROR
Ok. So we had the BCB not see the definition of new HWND. How do we make it work with, HWND where it expects Window.HWND? Is there a #define thing similar to C++? Even if this exists, since each delphi unit is a module, we would need to re-add the unit "windows" to "uses" of each unit that uses HWND, right? Regards, SZ - Original Message - From: "Francois PIETTE" <[EMAIL PROTECTED]> To: "ICS support mailing" Sent: Monday, March 13, 2006 10:09 PM Subject: Re: [twsocket] BDS2006 & C++Personality = ERROR >> There is no notion of real "module" in C++. Namespaces are invented to >> prevent name clashes for this purpose. You can have HWND and >> Overbyteics:HWND at the same scope UNLESS you define, >> >> using namespace Overbyteics; >> >> which makes the "::" = "Overbyteics" and which is the case with >> Overbyteics. >> It is like adding a path to Delphi/BCB. There cannot be same named >> components in the same project! What Francois should agree to do is to >> rename all of the HWND's in the ICS code with Overbyteics::HWND (or >> perhaps >> rename the namespace name to ObICS for the sake of compacting), IMO. > > He think this is C++ code. It isn't. It is Delphi code. > Instead, try conditionally compile the offending types redefinition in > OverbyteIcsTypes.pas so that BCB doesn't see them. > > -- > [EMAIL PROTECTED] > http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://www.elists.org/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] BDS2006 & C++Personality = ERROR
> There is no notion of real "module" in C++. Namespaces are invented to > prevent name clashes for this purpose. You can have HWND and > Overbyteics:HWND at the same scope UNLESS you define, > > using namespace Overbyteics; > > which makes the "::" = "Overbyteics" and which is the case with > Overbyteics. > It is like adding a path to Delphi/BCB. There cannot be same named > components in the same project! What Francois should agree to do is to > rename all of the HWND's in the ICS code with Overbyteics::HWND (or > perhaps > rename the namespace name to ObICS for the sake of compacting), IMO. He think this is C++ code. It isn't. It is Delphi code. Instead, try conditionally compile the offending types redefinition in OverbyteIcsTypes.pas so that BCB doesn't see them. -- [EMAIL PROTECTED] http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] BDS2006 & C++Personality = ERROR
- Original Message - From: "Francois PIETTE" <[EMAIL PROTECTED]> To: "ICS support mailing" Sent: Monday, March 13, 2006 8:52 PM Subject: Re: [twsocket] BDS2006 & C++Personality = ERROR > Use ICS V5 BETA with BDS2006/C++. > V6 has not been validated yet with BDS2006/C++. > >> Ambiguity between 'HWND' and >> 'Overbyteicstypes::HWND' >> Any ideas? > > I think some conditional compilation is needed to solve this problem. Not > sure. I had no time to dig into this problem yet. Of course you are > welcome > to solve it. I digged into this problem. Investigated in "The C++ Programming Language" by Bjarne Stroustroup and "C++ Primer" by Lippman, Lajole. After I found what I found, I asked for confirmation on Borland.public.cppbuilder.vcl.components.using newsgroup in Feb 27th and Gambit/Remy Lebeau from TeamB did. Here is what I think: There is no notion of real "module" in C++. Namespaces are invented to prevent name clashes for this purpose. You can have HWND and Overbyteics:HWND at the same scope UNLESS you define, using namespace Overbyteics; which makes the "::" = "Overbyteics" and which is the case with Overbyteics. It is like adding a path to Delphi/BCB. There cannot be same named components in the same project! What Francois should agree to do is to rename all of the HWND's in the ICS code with Overbyteics::HWND (or perhaps rename the namespace name to ObICS for the sake of compacting), IMO. Regards, SZ > > -- > [EMAIL PROTECTED] > http://www.overbyte.be > > ----- Original Message - > From: "Luca Centimeri" <[EMAIL PROTECTED]> > To: > Sent: Monday, March 13, 2006 4:44 PM > Subject: [twsocket] BDS2006 & C++Personality = ERROR > > >> Hello, >> I'm using BDS2006, c++ personality & ICS latest package, >> when I create an empty VCL Forms application, add a TWSocket component >> (also TWsocketServer) >> and I try to compile my empty app, I receive the following error: >> >> "[C++ Error] Overbyteicslibrary.hpp(43): E2040 Declaration terminated >> incorrectly" >> >> the errors is in the Overbyteicslibrary.hpp at the line: >> "static const Shortint WM_QUIT = 0x12;" >> >> Also, I receive another error at the line 75 that says that there's an >> Ambiguity between 'HWND' and >> 'Overbyteicstypes::HWND' >> >> Of course, if I do the same things in the Delphi personality, everything >> works fine. >> >> Any ideas? >> >> Luca Centimeri >> >> >> >> >> >> -- >> To unsubscribe or change your settings for TWSocket mailing list >> please goto http://www.elists.org/mailman/listinfo/twsocket >> Visit our website at http://www.overbyte.be > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://www.elists.org/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] BDS2006 & C++Personality = ERROR
Use ICS V5 BETA with BDS2006/C++. V6 has not been validated yet with BDS2006/C++. > Ambiguity between 'HWND' and > 'Overbyteicstypes::HWND' > Any ideas? I think some conditional compilation is needed to solve this problem. Not sure. I had no time to dig into this problem yet. Of course you are welcome to solve it. -- [EMAIL PROTECTED] http://www.overbyte.be - Original Message - From: "Luca Centimeri" <[EMAIL PROTECTED]> To: Sent: Monday, March 13, 2006 4:44 PM Subject: [twsocket] BDS2006 & C++Personality = ERROR > Hello, > I'm using BDS2006, c++ personality & ICS latest package, > when I create an empty VCL Forms application, add a TWSocket component > (also TWsocketServer) > and I try to compile my empty app, I receive the following error: > > "[C++ Error] Overbyteicslibrary.hpp(43): E2040 Declaration terminated > incorrectly" > > the errors is in the Overbyteicslibrary.hpp at the line: > "static const Shortint WM_QUIT = 0x12;" > > Also, I receive another error at the line 75 that says that there's an > Ambiguity between 'HWND' and > 'Overbyteicstypes::HWND' > > Of course, if I do the same things in the Delphi personality, everything > works fine. > > Any ideas? > > Luca Centimeri > > > > > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://www.elists.org/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
Re: [twsocket] BDS2006 & C++Personality = ERROR
Hello Luca, I assume you are using v6 and these are the same errors I reported for BCB6. The redeclaration of Windows constants and functions cause a lot of trouble for BCB and seamingly BDS2006 and this is an issue that MUST BE DEALED WITH in order for ICS to work under C++. Regards, SZ - Original Message - From: "Luca Centimeri" <[EMAIL PROTECTED]> To: Sent: Monday, March 13, 2006 5:44 PM Subject: [twsocket] BDS2006 & C++Personality = ERROR > Hello, > I'm using BDS2006, c++ personality & ICS latest package, > when I create an empty VCL Forms application, add a TWSocket component > (also TWsocketServer) > and I try to compile my empty app, I receive the following error: > > "[C++ Error] Overbyteicslibrary.hpp(43): E2040 Declaration terminated > incorrectly" > > the errors is in the Overbyteicslibrary.hpp at the line: > "static const Shortint WM_QUIT = 0x12;" > > Also, I receive another error at the line 75 that says that there's an > Ambiguity between 'HWND' and > 'Overbyteicstypes::HWND' > > Of course, if I do the same things in the Delphi personality, everything > works fine. > > Any ideas? > > Luca Centimeri > > > > > > -- > To unsubscribe or change your settings for TWSocket mailing list > please goto http://www.elists.org/mailman/listinfo/twsocket > Visit our website at http://www.overbyte.be -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
[twsocket] BDS2006 & C++Personality = ERROR
Hello, I'm using BDS2006, c++ personality & ICS latest package, when I create an empty VCL Forms application, add a TWSocket component (also TWsocketServer) and I try to compile my empty app, I receive the following error: "[C++ Error] Overbyteicslibrary.hpp(43): E2040 Declaration terminated incorrectly" the errors is in the Overbyteicslibrary.hpp at the line: "static const Shortint WM_QUIT = 0x12;" Also, I receive another error at the line 75 that says that there's an Ambiguity between 'HWND' and 'Overbyteicstypes::HWND' Of course, if I do the same things in the Delphi personality, everything works fine. Any ideas? Luca Centimeri -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be