opnsense-src/test/libcxx/strings/basic.string/string.modifiers/erase_pop_back_db1.pass.cpp

33 lines
671 B
C++
Raw Normal View History

2015-09-06 14:46:46 -04:00
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
// <string>
2015-09-06 14:46:46 -04:00
// void pop_back();
#if _LIBCPP_DEBUG >= 1
#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0))
#endif
2015-09-06 14:46:46 -04:00
#include <string>
2015-09-06 14:46:46 -04:00
#include <cassert>
#include "test_macros.h"
2015-09-06 14:46:46 -04:00
int main()
{
#if _LIBCPP_DEBUG >= 1
{
std::string s;
s.pop_back();
assert(false);
}
2015-09-06 14:46:46 -04:00
#endif
}