473,386 Members | 1,736 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Is Borland C++ COM compliant??

I need to access COM DLL from Borland C++.
I do not know if Borland C++ is COM compliant or not. I know that they
were bending over backward to be MFC compliant about 8 to 10 years ago
but I do not know if that includes COM. If it is compliant, which
version of Borland C++ we have to use?

Your input is greatly appreciated!!

Regards,
Rama

May 5 '06 #1
8 1998
ramki wrote:
I need to access COM DLL from Borland C++.


http://www.parashift.com/c++-faq-lit...t.html#faq-5.9
Jonathan

May 5 '06 #2
COM API may help you.

May 5 '06 #3
"ramki" <ra**********@gmail.com> wrote in message
news:11*********************@y43g2000cwc.googlegro ups.com...
:I need to access COM DLL from Borland C++.
: I do not know if Borland C++ is COM compliant or not. I know that they
: were bending over backward to be MFC compliant about 8 to 10 years ago
: but I do not know if that includes COM. If it is compliant, which
: version of Borland C++ we have to use?

No, by default, it uses a different ABI (binary interface/code layout)
than what is mandated by COM.
Ask in a Borland forum to find out more...

hth-Ivan
--
http://ivan.vecerina.com/contact/?subject=NG_POST <- email contact form
May 5 '06 #4
In message <6b***************************@news.hispeed.ch>, Ivan
Vecerina <IN*****************@ivan.vecerina.com> writes
"ramki" <ra**********@gmail.com> wrote in message
news:11*********************@y43g2000cwc.googlegr oups.com...
:I need to access COM DLL from Borland C++.
: I do not know if Borland C++ is COM compliant or not. I know that they
: were bending over backward to be MFC compliant about 8 to 10 years ago
: but I do not know if that includes COM. If it is compliant, which
: version of Borland C++ we have to use?

No,
Where "no" means "yes, but".
by default, it uses a different ABI (binary interface/code layout)
than what is mandated by COM.
Only by default. It can generate COM-compatible code if you use the
appropriate constructs, or let its wizards generate them for you. (Been
there, done that, sold it to satisfied customers...)

Which is why it's better to
Ask in a Borland forum to find out more...


instead of the incomplete and possibly incorrect information you'll get
here.

--
Richard Herring
May 8 '06 #5

ramki schreef:
I need to access COM DLL from Borland C++.


Long long time since I done this ... but I think the problem is the
name mangling difference between MVC++ and Borland. Mangling means that
to support overloading of method names in C++, MicroSoft VC++ and
Borland C++ Builder use different names and funny bits in names. If
your DLL only exists of pure C and hence the named functions do not
cantain this mangling, or how it was called, it can be done. This
because in pure C there is no function name overloading and hence no
mangling with funny parts in the function name.

Marc Wentink

May 8 '06 #6
Richard Herring wrote:
In message <6b***************************@news.hispeed.ch>, Ivan
Vecerina <IN*****************@ivan.vecerina.com> writes
"ramki" <ra**********@gmail.com> wrote in message
news:11*********************@y43g2000cwc.googlegro ups.com...
:I need to access COM DLL from Borland C++.
: I do not know if Borland C++ is COM compliant or not. I know that they
: were bending over backward to be MFC compliant about 8 to 10 years ago
: but I do not know if that includes COM. If it is compliant, which
: version of Borland C++ we have to use?

No,


Where "no" means "yes, but".
by default, it uses a different ABI (binary interface/code layout)
than what is mandated by COM.


Only by default. It can generate COM-compatible code if you use the
appropriate constructs, or let its wizards generate them for you. (Been
there, done that, sold it to satisfied customers...)

Which is why it's better to
Ask in a Borland forum to find out more...


instead of the incomplete and possibly incorrect information you'll get
here.

I know this is OT and therefore really naughty, but it's piqued my
curiosity because I'm currently reading Matthew Wilson's "Imperfect C++"
and there's a whole section on binary interoperability. By "binary
interface/code layout" above, are we talking about the arrangement of
the vtable layout and pointer?

--
Mike Smith
May 8 '06 #7
"Mike Smith" <mi*****************@acm.org> wrote in message
news:12*************@news.supernews.com...
: Richard Herring wrote:
: > In message <6b***************************@news.hispeed.ch>, Ivan
: > Vecerina <IN*****************@ivan.vecerina.com> writes
: >> "ramki" <ra**********@gmail.com> wrote in message
: >> news:11*********************@y43g2000cwc.googlegro ups.com...
: >> :I need to access COM DLL from Borland C++.
: >> : I do not know if Borland C++ is COM compliant or not. I know that
they
: >> : were bending over backward to be MFC compliant about 8 to 10 years
ago
: >> : but I do not know if that includes COM. If it is compliant, which
: >> : version of Borland C++ we have to use?
: >>
: >> No,
: >
: > Where "no" means "yes, but".
: >
: >> by default, it uses a different ABI (binary interface/code layout)
: >> than what is mandated by COM.
: >
: > Only by default. It can generate COM-compatible code if you use the
: > appropriate constructs, or let its wizards generate them for you.
(Been
: > there, done that, sold it to satisfied customers...)
: >
: > Which is why it's better to
: >
: >> Ask in a Borland forum to find out more...
: >
: > instead of the incomplete and possibly incorrect information you'll
get
: > here.
:
:
: I know this is OT and therefore really naughty, but it's piqued my
: curiosity because I'm currently reading Matthew Wilson's "Imperfect C++"
: and there's a whole section on binary interoperability. By "binary
: interface/code layout" above, are we talking about the arrangement of
: the vtable layout and pointer?

Yes, if I dare:

The MS COM specification requires a vtable made of a simple array of
function pointers. This is the approach that is most-easily emulated
by an array of C function pointers.
Its weakness, when using multiple inheritance, is that stub "trampoline"
functions need to be inserted to adjust the this pointer.

My guess is that Borland (just as Metrowerks used to do on the PowerPC
platform) uses the other popular form, where each vtable entry includes
both a function pointer and an offset to be applied to the this pointer.
[but I might be wrong regarding this point]

Another difference is that Borland's compiler, by default, uses different
parameter-passing conventions (e.g. using registers when possible).
And this is all good, but does required some extra effort when wanting
to interface with COM.
My 2 cents... Ivan
--
http://ivan.vecerina.com/contact/?subject=NG_POST <- email contact form
May 8 '06 #8
Ivan Vecerina wrote:
"Mike Smith" <mi*****************@acm.org> wrote in message
news:12*************@news.supernews.com...
: Richard Herring wrote:
: > In message <6b***************************@news.hispeed.ch>, Ivan
: > Vecerina <IN*****************@ivan.vecerina.com> writes
: >> "ramki" <ra**********@gmail.com> wrote in message
: >> news:11*********************@y43g2000cwc.googlegro ups.com...
: >> :I need to access COM DLL from Borland C++.
: >> : I do not know if Borland C++ is COM compliant or not. I know that
they
: >> : were bending over backward to be MFC compliant about 8 to 10 years
ago
: >> : but I do not know if that includes COM. If it is compliant, which
: >> : version of Borland C++ we have to use?
: >>
: >> No,
: >
: > Where "no" means "yes, but".
: >
: >> by default, it uses a different ABI (binary interface/code layout)
: >> than what is mandated by COM.
: >
: > Only by default. It can generate COM-compatible code if you use the
: > appropriate constructs, or let its wizards generate them for you.
(Been
: > there, done that, sold it to satisfied customers...)
: >
: > Which is why it's better to
: >
: >> Ask in a Borland forum to find out more...
: >
: > instead of the incomplete and possibly incorrect information you'll
get
: > here.
:
:
: I know this is OT and therefore really naughty, but it's piqued my
: curiosity because I'm currently reading Matthew Wilson's "Imperfect C++"
: and there's a whole section on binary interoperability. By "binary
: interface/code layout" above, are we talking about the arrangement of
: the vtable layout and pointer?

Yes, if I dare:


Thanks for taking such a risk... ;-)

--
Mike Smith
May 10 '06 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Developwebsites | last post by:
do they have 5.5 with an IDE? I've used 3.1 and 4.52, so why should i go back to command line with 5.5? are there any other C++ compilers with an IDE? ...
1
by: Nimmi Srivastav | last post by:
There's a rather nondescript book called "Using Borland C++" by Lee and Mark Atkinson (Que Corporation) which presents an excellent discussion of overloaded new and delete operators. In fact there...
17
by: Ziggi | last post by:
Hi. I want to get a C++ IDE, but I dont know whether to go for Bill Gate's solution or Borland's. Could any kind folks detail the relative strength and weaknesses of both, and also tell me which...
9
by: Christo | last post by:
hey im a student about to start a course in c++ at uni, we have been told to obtain a copy of borland c++ 5.01 (not c++ builder) this is just a program with a compiler/linker and development...
24
by: serdar | last post by:
Hi. Does anybody say that what is better borland c++ or visual c++? Which compiler does have more help?
4
by: Mufe | last post by:
Visual c++ compiler survives this: #define THE_NULL -32767 struct typePair { int v2,v3; }; struct typeTriple { int v1; typePair p; }; typePair EMPTY_PAIR = {THE_NULL,THE_NULL}; typeTriple...
1
by: ramkivelpuri | last post by:
I need to access COM DLL from Borland C++. I do not know if Borland C++ is COM compliant or not. I know that they were bending over backward to be MFC compliant about 8 to 10 years ago but I do not...
1
by: Terry | last post by:
Is there any hope of using Borland Developer Studio 2006 to link in a DLL compiled by MS Visual C++ version 6? I have a Win32 DLL from a company named Vocera. The DLL defines C++ classes that I...
7
by: Frederick Williams | last post by:
Does anybody know where I can download Borland C++ 4.52 from? Some years ago it was available "free" on a magazine cover. So I'm hoping that it's available from somewhere without upsetting the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.