I am writing a COM object in C++ using ATL and am not sure whether I should be using VARIANT_BOOL
for my methods/properties or not. The object will be called by other C++ apps but I cannot rule out usage from .NET.
I can stick to good old BOOL
(which IIRC is simply an unsigned int) but as VARIANT_BOOL
is there, shouldn't I be using it? If I do use it, and call these methods from a C++ app, I have to add extra code as a VARIANT_BOOL
is not like a 'normal' boolean and I have to check for VARIANT_TRUE
and VARIANT_FALSE
values.
Is VARIANT_BOOL
an anachronism that I can forget or should I stick with it?