[range] BOOST_RANGE_DEDUCED_TYPENAME

In range/config.hpp, I see this code... #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) #define BOOST_RANGE_DEDUCED_TYPENAME #else #define BOOST_RANGE_DEDUCED_TYPENAME BOOST_DEDUCED_TYPENAME #endif Why is there a special version of this? It is only defined to empty, or BOOST_DEDUCED_TYPENAME. What is wrong with simply using BOOST_DEDUCED_TYPENAME? If there is a problem with the "stock" one? If so, shouldn't that be changed instead?

"Jody Hagins" <jody-boost-011304@atdesk.com> wrote in message news:20050302125807.4bb8b676.jody-boost-011304@atdesk.com... | | In range/config.hpp, I see this code... | | | #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) | #define BOOST_RANGE_DEDUCED_TYPENAME | #else | #define BOOST_RANGE_DEDUCED_TYPENAME BOOST_DEDUCED_TYPENAME | #endif | | | Why is there a special version of this? I guess the explanation would be historic reasons, I used it in some workaround code. It will go away in the next release. -Thorsten

"Thorsten Ottosen" <nesotto@cs.auc.dk> writes:
"Jody Hagins" <jody-boost-011304@atdesk.com> wrote in message news:20050302125807.4bb8b676.jody-boost-011304@atdesk.com... | | In range/config.hpp, I see this code... | | | #if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) | #define BOOST_RANGE_DEDUCED_TYPENAME | #else | #define BOOST_RANGE_DEDUCED_TYPENAME BOOST_DEDUCED_TYPENAME | #endif | | | Why is there a special version of this?
I guess the explanation would be historic reasons, I used it in some workaround code. It will go away in the next release.
It's on my outstanding mental list of Boost-wide changes that BOOST_DEDUCED_TYPENAME should be changed simply to BOOST_TYPENAME, because it's used in all kinds of contexts where there's no deduction involved. Older compilers simply need a disappearing "typename" keyword, and that's the role that it fills. -- Dave Abrahams Boost Consulting www.boost-consulting.com
participants (3)
-
David Abrahams
-
Jody Hagins
-
Thorsten Ottosen