summaryrefslogtreecommitdiffstats
path: root/libcxx/test/std/re/re.regex/re.regex.construct
diff options
context:
space:
mode:
Diffstat (limited to 'libcxx/test/std/re/re.regex/re.regex.construct')
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/awk_oct.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/bad_backref.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/bad_ctype.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/bad_escape.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/bad_repeat.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/copy.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/deduct.fail.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/deduct.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/default.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/il_flg.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/iter_iter.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/iter_iter_flg.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/ptr.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/ptr_flg.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/ptr_size.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/ptr_size_flg.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/string.pass.cpp4
-rw-r--r--libcxx/test/std/re/re.regex/re.regex.construct/string_flg.pass.cpp4
18 files changed, 54 insertions, 18 deletions
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/awk_oct.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/awk_oct.pass.cpp
index eabf8eab9f2..2e7eed350c0 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/awk_oct.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/awk_oct.pass.cpp
@@ -17,7 +17,7 @@
#include <cassert>
#include "test_macros.h"
-int main()
+int main(int, char**)
{
using std::regex_constants::awk;
@@ -25,4 +25,6 @@ int main()
assert(std::regex_match("\41", std::regex("\\41", awk)));
assert(std::regex_match("\141", std::regex("\\141", awk)));
assert(std::regex_match("\141" "1", std::regex("\\1411", awk)));
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/bad_backref.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/bad_backref.pass.cpp
index cc1b081c7df..0a15b6453c8 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/bad_backref.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/bad_backref.pass.cpp
@@ -29,7 +29,7 @@ static bool error_badbackref_thrown(const char *pat)
return result;
}
-int main()
+int main(int, char**)
{
assert(error_badbackref_thrown("\\1abc")); // no references
assert(error_badbackref_thrown("ab(c)\\2def")); // only one reference
@@ -41,4 +41,6 @@ int main()
const char *pat1 = "a(b)c\\1234";
std::regex re(pat1, pat1 + 7); // extra chars after the end.
}
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/bad_ctype.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/bad_ctype.pass.cpp
index dc24531cb48..5752d5cd681 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/bad_ctype.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/bad_ctype.pass.cpp
@@ -29,8 +29,10 @@ static bool error_ctype_thrown(const char *pat)
return result;
}
-int main()
+int main(int, char**)
{
assert(error_ctype_thrown("[[::]]"));
assert(error_ctype_thrown("[[:error:]]"));
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/bad_escape.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/bad_escape.pass.cpp
index f9e589ce7c7..041d55bdf88 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/bad_escape.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/bad_escape.pass.cpp
@@ -29,7 +29,7 @@ static bool error_escape_thrown(const char *pat)
return result;
}
-int main()
+int main(int, char**)
{
assert(error_escape_thrown("[\\a]"));
assert(error_escape_thrown("\\a"));
@@ -44,4 +44,6 @@ int main()
assert(!error_escape_thrown("[\\cA]"));
assert(!error_escape_thrown("\\cA"));
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/bad_repeat.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/bad_repeat.pass.cpp
index 2d07e1e8cf3..1af8b5ba651 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/bad_repeat.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/bad_repeat.pass.cpp
@@ -29,7 +29,7 @@ static bool error_badrepeat_thrown(const char *pat)
return result;
}
-int main()
+int main(int, char**)
{
assert(error_badrepeat_thrown("?a"));
assert(error_badrepeat_thrown("*a"));
@@ -40,4 +40,6 @@ int main()
assert(error_badrepeat_thrown("*(a+)"));
assert(error_badrepeat_thrown("+(a+)"));
assert(error_badrepeat_thrown("{(a+)"));
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/copy.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/copy.pass.cpp
index 588f673bf4f..f3db8fe0611 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/copy.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/copy.pass.cpp
@@ -16,10 +16,12 @@
#include <cassert>
#include "test_macros.h"
-int main()
+int main(int, char**)
{
std::regex r1("(a([bc]))");
std::regex r2 = r1;
assert(r2.flags() == std::regex::ECMAScript);
assert(r2.mark_count() == 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/deduct.fail.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/deduct.fail.cpp
index 5ece59ad263..30ec49c833b 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/deduct.fail.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/deduct.fail.cpp
@@ -24,7 +24,7 @@
#include <cstddef>
-int main()
+int main(int, char**)
{
// Test the explicit deduction guides
{
@@ -41,4 +41,6 @@ int main()
// Test the implicit deduction guides
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/deduct.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/deduct.pass.cpp
index 5d7493ae640..47e5a1dba7f 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/deduct.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/deduct.pass.cpp
@@ -31,7 +31,7 @@ using namespace std::literals;
struct A {};
-int main()
+int main(int, char**)
{
// Test the explicit deduction guides
@@ -133,4 +133,6 @@ int main()
assert(re.flags() == std::regex_constants::grep);
assert(re.mark_count() == 0);
}
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/default.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/default.pass.cpp
index b5c1521fce5..f706229e683 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/default.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/default.pass.cpp
@@ -25,8 +25,10 @@ test()
assert(r.mark_count() == 0);
}
-int main()
+int main(int, char**)
{
test<char>();
test<wchar_t>();
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/il_flg.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/il_flg.pass.cpp
index aac13147e81..aaf5bc25a7c 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/il_flg.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/il_flg.pass.cpp
@@ -29,7 +29,7 @@ test(std::initializer_list<char> il, std::regex_constants::syntax_option_type f,
}
-int main()
+int main(int, char**)
{
std::string s1("\\(a\\)");
std::string s2("\\(a[bc]\\)");
@@ -65,4 +65,6 @@ int main()
test({'\\', '(', 'a', '[', 'b', 'c', ']', '\\', ')'}, std::regex_constants::egrep, 0);
test({'\\', '(', 'a', '\\', '(', '[', 'b', 'c', ']', '\\', ')', '\\', ')'}, std::regex_constants::egrep, 0);
test({'(', 'a', '(', '[', 'b', 'c', ']', ')', ')'}, std::regex_constants::egrep, 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter.pass.cpp
index 0b5d0c50413..3dcf29fa009 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter.pass.cpp
@@ -28,7 +28,7 @@ test(Iter first, Iter last, unsigned mc)
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
typedef forward_iterator<std::string::const_iterator> F;
std::string s1("\\(a\\)");
@@ -40,4 +40,6 @@ int main()
test(F(s2.begin()), F(s2.end()), 0);
test(F(s3.begin()), F(s3.end()), 0);
test(F(s4.begin()), F(s4.end()), 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter_flg.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter_flg.pass.cpp
index 37878347f95..22423c09282 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter_flg.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/iter_iter_flg.pass.cpp
@@ -29,7 +29,7 @@ test(Iter first, Iter last, std::regex_constants::syntax_option_type f, unsigned
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
typedef forward_iterator<std::string::const_iterator> F;
std::string s1("\\(a\\)");
@@ -66,4 +66,6 @@ int main()
test(F(s2.begin()), F(s2.end()), std::regex_constants::egrep, 0);
test(F(s3.begin()), F(s3.end()), std::regex_constants::egrep, 0);
test(F(s4.begin()), F(s4.end()), std::regex_constants::egrep, 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/ptr.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/ptr.pass.cpp
index 877b9a4c6ee..b71d9eb7f49 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/ptr.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/ptr.pass.cpp
@@ -25,10 +25,12 @@ test(const CharT* p, unsigned mc)
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
test("\\(a\\)", 0);
test("\\(a[bc]\\)", 0);
test("\\(a\\([bc]\\)\\)", 0);
test("(a([bc]))", 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/ptr_flg.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/ptr_flg.pass.cpp
index 998f28db892..e918b03116b 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/ptr_flg.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/ptr_flg.pass.cpp
@@ -25,7 +25,7 @@ test(const CharT* p, std::regex_constants::syntax_option_type f, unsigned mc)
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
test("\\(a\\)", std::regex_constants::basic, 1);
test("\\(a[bc]\\)", std::regex_constants::basic, 1);
@@ -56,4 +56,6 @@ int main()
test("\\(a[bc]\\)", std::regex_constants::egrep, 0);
test("\\(a\\([bc]\\)\\)", std::regex_constants::egrep, 0);
test("(a([bc]))", std::regex_constants::egrep, 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size.pass.cpp
index 03a53b76979..29fa3ca57ac 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size.pass.cpp
@@ -24,7 +24,7 @@ test(const CharT* p, std::size_t len, unsigned mc)
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
test("\\(a\\)", 5, 0);
test("\\(a[bc]\\)", 9, 0);
@@ -35,4 +35,6 @@ int main()
test("(\0)(b)(c)(d)", 9, 3);
test("(\0)(b)(c)(d)", 3, 1);
test("(\0)(b)(c)(d)", 0, 0);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size_flg.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size_flg.pass.cpp
index 8546c167355..07f3947318e 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size_flg.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/ptr_size_flg.pass.cpp
@@ -26,7 +26,7 @@ test(const CharT* p, std::size_t len, std::regex_constants::syntax_option_type f
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
test("\\(a\\)", 5, std::regex_constants::basic, 1);
test("\\(a[bc]\\)", 9, std::regex_constants::basic, 1);
@@ -57,4 +57,6 @@ int main()
test("\\(a[bc]\\)", 9, std::regex_constants::egrep, 0);
test("\\(a\\([bc]\\)\\)", 13, std::regex_constants::egrep, 0);
test("(a([bc]))", 9, std::regex_constants::egrep, 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/string.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/string.pass.cpp
index 58f607183e9..ecd0451d82b 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/string.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/string.pass.cpp
@@ -26,10 +26,12 @@ test(const String& p, unsigned mc)
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
test(std::string("\\(a\\)"), 0);
test(std::string("\\(a[bc]\\)"), 0);
test(std::string("\\(a\\([bc]\\)\\)"), 0);
test(std::string("(a([bc]))"), 2);
+
+ return 0;
}
diff --git a/libcxx/test/std/re/re.regex/re.regex.construct/string_flg.pass.cpp b/libcxx/test/std/re/re.regex/re.regex.construct/string_flg.pass.cpp
index 6d504db3334..b6bd8c53c5a 100644
--- a/libcxx/test/std/re/re.regex/re.regex.construct/string_flg.pass.cpp
+++ b/libcxx/test/std/re/re.regex/re.regex.construct/string_flg.pass.cpp
@@ -27,7 +27,7 @@ test(const String& p, std::regex_constants::syntax_option_type f, unsigned mc)
assert(r.mark_count() == mc);
}
-int main()
+int main(int, char**)
{
test(std::string("\\(a\\)"), std::regex_constants::basic, 1);
test(std::string("\\(a[bc]\\)"), std::regex_constants::basic, 1);
@@ -58,4 +58,6 @@ int main()
test(std::string("\\(a[bc]\\)"), std::regex_constants::egrep, 0);
test(std::string("\\(a\\([bc]\\)\\)"), std::regex_constants::egrep, 0);
test(std::string("(a([bc]))"), std::regex_constants::egrep, 2);
+
+ return 0;
}
OpenPOWER on IntegriCloud