Simply debug mode tests per Dmitri Gribenko's suggestion.

llvm-svn: 178026
This commit is contained in:
Howard Hinnant 2013-03-26 14:28:25 +00:00
parent cf3d5aaea9
commit ea95898f29
21 changed files with 21 additions and 148 deletions

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
const C c;

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
const C c;

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
const C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c1;

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c1;

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c1;

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,7 +13,7 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
@ -21,14 +21,8 @@
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
typedef int T;
typedef std::vector<T> C;
C c(1);

View File

@ -13,21 +13,15 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
#include <cstdlib>
#include <exception>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
int a1[] = {1, 2, 3};
std::vector<int> l1(a1, a1+3);
std::vector<int>::const_iterator i = l1.end();

View File

@ -13,21 +13,15 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
#include <cstdlib>
#include <exception>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
int a1[] = {1, 2, 3};
std::vector<int> l1(a1, a1+3);
std::vector<int> l2(a1, a1+3);

View File

@ -13,21 +13,15 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
int a1[] = {1, 2, 3};
std::vector<int> l1(a1, a1+3);
std::vector<int> l2(a1, a1+3);

View File

@ -13,21 +13,15 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
int a1[] = {1, 2, 3};
std::vector<int> l1(a1, a1+3);
std::vector<int> l2(a1, a1+3);

View File

@ -13,21 +13,15 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
int a1[] = {1, 2, 3};
std::vector<int> l1(a1, a1+3);
std::vector<int> l2(a1, a1+3);

View File

@ -13,21 +13,15 @@
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#include <vector>
#include <cassert>
#include <exception>
#include <cstdlib>
void f1()
{
std::exit(0);
}
int main()
{
std::set_terminate(f1);
int a1[] = {1, 2, 3};
std::vector<int> l1(a1, a1+3);
std::vector<int>::iterator i = l1.erase(l1.cbegin()+1, l1.cbegin());

View File

@ -12,7 +12,7 @@
// void pop_back();
#if _LIBCPP_DEBUG2 >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::terminate())
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#endif
#include <vector>
@ -23,17 +23,10 @@
#include <cstdlib>
#include <exception>
void f1()
{
std::exit(0);
}
#endif
int main()
{
#if _LIBCPP_DEBUG2 >= 1
std::set_terminate(f1);
#endif
{
std::vector<int> c;
c.push_back(1);