Searched refs:noexcept (Results 1 - 25 of 267) sorted by relevance

1234567891011

/external/clang/test/CXX/expr/expr.unary/expr.unary.noexcept/
H A Dser.h1 // Serialization testing helper for noexcept, included by cg.cpp.
4 return noexcept(0);
7 return noexcept(throw 0);
H A Dcg.cpp16 b = noexcept(0);
18 b = noexcept(throw 0);
24 D(), noexcept(E());
/external/clang/test/CXX/except/except.spec/
H A Dp15.cpp13 // Deallocation functions are implicitly noexcept.
19 static_assert(noexcept(operator delete(0)), "");
20 static_assert(noexcept(operator delete[](0)), "");
26 static_assert(noexcept(operator delete(0, 0.f)), "");
27 static_assert(noexcept(operator delete[](0, 0.f)), "");
31 static_assert(!noexcept(operator delete(0, 0.)), "");
32 void operator delete(void*, double) noexcept; // expected-error {{does not match}}
H A Dp2-places.cpp46 void f() noexcept(false);
48 void (*fp)() noexcept(false);
50 void g(void pfa() noexcept(false));
52 typedef int (*pf)() noexcept(false); // expected-error {{specifications are not allowed in typedefs}} typedef in namespace:noex
54 void (*h())() noexcept(false);
56 void (*i() noexcept(false))(void (*)() noexcept(true)) noexcept(false);
58 void (**k)(void pfa() noexcept(false)); // no-error
60 void (**j)() noexcept(fals
[all...]
H A Dp9-noexcept.cpp5 void target() noexcept
16 void reverse() noexcept(false) function
H A Dp3.cpp44 // noexcept is compatible with itself
45 extern void (*r10)() noexcept;
46 extern void (*r10)() noexcept;
48 // noexcept(true) is compatible with noexcept
49 extern void (*r11)() noexcept;
50 extern void (*r11)() noexcept(true);
52 // noexcept(false) isn't
53 extern void (*r12)() noexcept; // expected-note {{previous declaration}}
54 extern void (*r12)() noexcept(fals
[all...]
H A Dp1.cpp25 // Simple parser tests, noexcept specification.
29 void f1() noexcept { }
30 void f2() noexcept (true) { } function in namespace:noex
31 void f3() noexcept (false) { } function in namespace:noex
32 void f4() noexcept (1 < 2) { }
35 void foo() noexcept { }
36 void bar() noexcept (true) { } function in class:noex::CA1
39 void (*fptr1)() noexcept; member in namespace:noex
40 void (*fptr2)() noexcept (true);
46 void f() throw(int) noexcept { } // expecte
68 noexcept(sizeof(T) == sizeof(int)) || noexcept(f(x)) argument
[all...]
H A Dp11.cpp5 void f() noexcept {
H A Dp5-virtual.cpp35 virtual void f7() noexcept; member in struct:Base
36 virtual void f8() noexcept; member in struct:Base
37 virtual void f9() noexcept(false);
38 virtual void f10() noexcept(false);
41 virtual void f12() noexcept; member in struct:Base
42 virtual void f13() noexcept(false);
54 virtual void g6() noexcept; // expected-note {{overridden virtual function is here}} member in struct:Base
55 virtual void g7() noexcept; // expected-note {{overridden virtual function is here}} member in struct:Base
57 virtual void g8() noexcept; // expected-note {{overridden virtual function is here}} member in struct:Base
71 virtual void f7() noexcept; member in struct:Derived
76 virtual void f11() noexcept; member in struct:Derived
81 virtual void f15() noexcept; member in struct:Derived
[all...]
H A Dtemplate.cpp6 template <int N> void f2() noexcept(N > 1);
11 void (*t3)() noexcept = &f2<2>; // no-error
12 void (*t4)() noexcept = &f2<0>; // expected-error {{not superset}}
H A Dp4.cpp12 void S::a() noexcept {} // expected-error {{does not match previous}}
13 S::~S() noexcept {} // expected-warning {{function previously declared with an implicit exception specification redeclared with an explicit exception specification}}
14 void S::operator delete(void*) noexcept {} // expected-warning {{function previously declared with an implicit exception specification redeclared with an explicit exception specification}}
17 void a() noexcept; // expected-note {{here}} member in struct:T
18 ~T() noexcept; // expected-note {{here}} member in struct:T
19 void operator delete(void*) noexcept; // expected-note {{here}} member in struct:T
22 void T::a() {} // expected-error {{missing exception specification 'noexcept'}}
35 template<typename T> U<T>::~U() noexcept(true) {} // expected-error {{exception specification in declaration does not match previous declaration}} function
36 template<typename T> void U<T>::operator delete(void*) noexcept(false) {} // expected-error {{exception specification in declaration does not match previous declaration}} function
H A Dp14.cpp40 static_assert(noexcept(IC0()), "IC0() does not throw");
41 static_assert(!noexcept(IC1()), "IC1() throws");
46 NoThrowMove(NoThrowMove &&) noexcept; member in struct:PR13381::NoThrowMove
48 NoThrowMove &operator=(NoThrowMove &&) const noexcept; member in struct:PR13381::NoThrowMove
51 NoThrowMoveOnly(NoThrowMoveOnly &&) noexcept; member in struct:PR13381::NoThrowMoveOnly
52 NoThrowMoveOnly &operator=(NoThrowMoveOnly &&) noexcept; member in struct:PR13381::NoThrowMoveOnly
63 static_assert(!noexcept(X(X::val())), "");
64 static_assert(!noexcept(X::ref() = X::val()), "");
68 // Part of DR1351: the implicit exception-specification is noexcept(false) if
70 // "any". Hence it is compatible with noexcept(fals
[all...]
/external/clang/test/CodeGenCXX/
H A Dmicrosoft-abi-eh-terminate.cpp5 void never_throws() noexcept(true) { function
H A Ddestructor-crash.cpp16 ~C() noexcept; member in struct:C
19 C::~C() noexcept {}
H A Dnoexcept.cpp5 // std::terminate in a noexcept function.
14 void test() noexcept {
/external/clang/test/SemaCXX/
H A Dcxx0x-noexcept-expression.cpp7 bool b = noexcept(f); // expected-error {{reference to overloaded function could not be resolved; did you mean to call it with no arguments?}}
8 bool b2 = noexcept(f(0));
16 bool b = noexcept(this->g); // expected-error {{reference to non-static member function must be called; did you mean to call it with no arguments?}}
17 bool b2 = noexcept(this->g(0));
H A Dcxx1y-sized-deallocation.cpp4 void operator delete(void *, size_t) noexcept; // expected-note {{'operator delete' declared here}}
5 void operator delete[](void *, size_t) noexcept;
11 static_assert(noexcept(operator delete(p, 8)), "");
12 static_assert(noexcept(operator delete[](q, 12)), "");
H A Dwarn-unused-value-cxx11.cpp18 (void)noexcept(++i); // expected-warning {{expression with side effects has no effect in an unevaluated context}}
34 (void)noexcept(s++); // Ok
35 (void)noexcept(i++); // expected-warning {{expression with side effects has no effect in an unevaluated context}}
36 (void)noexcept(i = 5); // expected-warning {{expression with side effects has no effect in an unevaluated context}}
37 (void)noexcept(s = 5); // Ok
41 (void)noexcept(s.g() = 5); // Ok
H A Dimplicit-exception-spec.cpp11 // Noexcept::Noexcept() is implicitly declared as noexcept(false), because it
14 // If noexcept(Noexcept()) is false, then Noexcept() is a constant expression,
15 // so noexcept(Noexcept()) is true. But if noexcept(Noexcept()) is true, then
16 // Noexcept::Noexcept is not declared constexpr, therefore noexcept(Noexcept())
18 bool ThrowSomething() noexcept(false);
20 bool b = noexcept(ConstExpr()) && ThrowSomething(); // expected-error {{cannot use defaulted default constructor of 'ConstExpr' within the class outside of member functions}}
25 // knowing whether it produces a noexcept expression.
27 int n = ExceptionIf<noexcept(TemplateArg())>::f(); // expected-error {{cannot use defaulted default constructor of 'TemplateArg' within the class outside of member functions}}
35 int n = ExceptionIf<noexcept(Neste
[all...]
/external/libcxx/src/
H A Dvariant.cpp14 const char* bad_variant_access::what() const noexcept {
/external/clang/test/SemaTemplate/
H A Dinstantiation-depth-exception-spec.cpp3 template<typename T> T go(T a) noexcept(noexcept(go(a))); // \
H A Dinstantiation-depth.cpp22 S() noexcept(noexcept(T()));
/external/libcxx/test/std/utilities/meta/meta.unary/meta.unary.cat/
H A Dmember_function_pointer.pass.cpp83 test_member_function_pointer<void (Class::*)() noexcept>();
84 test_member_function_pointer<void (Class::*)(int) noexcept>();
85 test_member_function_pointer<void (Class::*)(int, char) noexcept>();
87 test_member_function_pointer<void (Class::*)() const noexcept>();
88 test_member_function_pointer<void (Class::*)(int) const noexcept>();
89 test_member_function_pointer<void (Class::*)(int, char) const noexcept>();
91 test_member_function_pointer<void (Class::*)() volatile noexcept>();
92 test_member_function_pointer<void (Class::*)(int) volatile noexcept>();
93 test_member_function_pointer<void (Class::*)(int, char) volatile noexcept>();
95 test_member_function_pointer<void (Class::*)(...) noexcept>();
[all...]
/external/clang/test/CXX/expr/expr.prim/expr.prim.general/
H A Dp3-0x.cpp5 float &f(int*) const noexcept; member in struct:A
8 auto g1() noexcept(noexcept(f(ptr))) -> decltype(f(this->ptr));
9 auto g2() const noexcept(noexcept(f((*this).ptr))) -> decltype(f(ptr));
15 static_assert(!noexcept(a.g1()), "exception-specification failure");
16 static_assert(noexcept(a.g2()), "exception-specification failure");
30 float &f(T*) const noexcept; member in struct:C
33 auto g1() noexcept(noexcept(
76 iter_swap(I x, I y) noexcept; member in namespace:PR10036
143 void foo(Derived& d) noexcept(noexcept(d.bar(d))) {} function in struct:PR12564::Derived
[all...]
/external/clang/test/CXX/dcl.decl/dcl.fct.def/dcl.fct.def.default/
H A Dp2.cpp62 E1() noexcept = default; member in struct:E1
63 E1(const E1&) noexcept = default; member in struct:E1
64 E1(E1&&) noexcept = default; member in struct:E1
65 E1 &operator=(const E1&) noexcept = default; member in struct:E1
66 E1 &operator=(E1&&) noexcept = default; member in struct:E1
67 ~E1() noexcept = default; member in struct:E1
70 E2() noexcept(false) = default; // expected-error {{exception specification of explicitly defaulted default constructor does not match the calculated one}}
71 E2(const E2&) noexcept(false) = default; // expected-error {{exception specification of explicitly defaulted copy constructor does not match the calculated one}}
72 E2(E2&&) noexcept(false) = default; // expected-error {{exception specification of explicitly defaulted move constructor does not match the calculated one}}
73 E2 &operator=(const E2&) noexcept(fals
[all...]

Completed in 691 milliseconds

1234567891011