Boost logo

Boost :

From: Daniel Frey (daniel.frey_at_[hidden])
Date: 2003-03-06 09:05:16


David Abrahams wrote:
>
> Daniel Frey <daniel.frey_at_[hidden]> writes:
>
> > I greped for it and it seems it is not used very often. How about using
> > BOOST_WORKAROUND to keep the code local and thus not hide the actual
> > workaround in a MACRO and spread to knowledge? Especially given it's
> > only a workaround for a single compiler. Or do you think it is
> > comparable to BOOST_STATIC_CONSTANT
>
> I do.

The difference I see is, that BOOST_STATIC_CONSTANT switches between two
legal alternatives, while BOOST_DEDUCED_TYPENAME only hides
non-conforming code (IIUC) which is required for some compilers.

> > and will be used a lot in the future
>
> Maybe not a lot, but often enough. I'm sure we have quite a few
> synonyms for it in various headers. Did you search for just
> "TYPENAME"?

No, I greped for BOOST_DEDUCED_TYPENAME

> I find
>
> BOOST_ARG_DEPENDENT_TYPENAME
> BOOST_MSVC_TYPENAME
> BOOST_DEDUCED_TYPENAME
> BOOST_UBLAS_TYPENAME
> BOOST_SPIRIT_TYPENAME... etc.
>
> OK, I'm tired of typing these now.
>
> It really uglifies code to have to add the workaround every place you
> need it.

Agreed. I didn't know about the other MACROs. I just found the one (or
two?) occasions where BOOST_DEDUCED_TYPENAME was used. Generally I think
it's better to have things as local as possible, but if the above
workaround is needed often, it might make sense to keep the macro and if
I understand you correctly, the new macro will replace all of the above
macros, right?

Regards, Daniel

-- 
Daniel Frey
aixigo AG - financial training, research and technology
Schloß-Rahe-Straße 15, 52072 Aachen, Germany
fon: +49 (0)241 936737-42, fax: +49 (0)241 936737-99
eMail: daniel.frey_at_[hidden], web: http://www.aixigo.de

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk