mirror of
https://github.com/catchorg/Catch2.git
synced 2025-09-18 10:55:39 +02:00
Merge pull request #1 from afoster1/master
Need support for Sun Studio 12.1
This commit is contained in:
@@ -119,6 +119,16 @@
|
||||
|
||||
#endif // _MSC_VER
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Oracle Solaris Studio
|
||||
#ifdef __SUNPRO_CC
|
||||
|
||||
# if __SUNPRO_CC == 0x5100 // Oracle Solaris Studio version 12.1
|
||||
# define CATCH_INTERNAL_SUNPRO_CC_NON_COMPLIANT_STL
|
||||
# endif
|
||||
|
||||
#endif // __SUNPRO_CC
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// Use variadic macros if the compiler supports them
|
||||
|
@@ -327,8 +327,9 @@ namespace Catch {
|
||||
void handleUnfinishedSections() {
|
||||
// If sections ended prematurely due to an exception we stored their
|
||||
// infos here so we can tear them down outside the unwind process.
|
||||
for( std::vector<SectionEndInfo>::const_reverse_iterator it = m_unfinishedSections.rbegin(),
|
||||
itEnd = m_unfinishedSections.rend();
|
||||
std::vector<SectionEndInfo> const& constUnfinishedSections = m_unfinishedSections;
|
||||
for( std::vector<SectionEndInfo>::const_reverse_iterator it = constUnfinishedSections.rbegin(),
|
||||
itEnd = constUnfinishedSections.rend();
|
||||
it != itEnd;
|
||||
++it )
|
||||
sectionEnded( *it );
|
||||
|
@@ -48,7 +48,7 @@ namespace Catch {
|
||||
oss << "error: tag alias, \"" << alias << "\" is not of the form [@alias name].\n" << lineInfo;
|
||||
throw std::domain_error( oss.str().c_str() );
|
||||
}
|
||||
if( !m_registry.insert( std::make_pair( alias, TagAlias( tag, lineInfo ) ) ).second ) {
|
||||
if( !m_registry.insert( std::make_pair( std::string(alias), TagAlias( tag, lineInfo ) ) ).second ) {
|
||||
std::ostringstream oss;
|
||||
oss << "error: tag alias, \"" << alias << "\" already registered.\n"
|
||||
<< "\tFirst seen at " << find(alias)->lineInfo << "\n"
|
||||
|
Reference in New Issue
Block a user