plateform
stringclasses 1
value | repo_name
stringclasses 2
values | name
stringlengths 1
78
| ext
stringclasses 2
values | path
stringlengths 15
1.11k
| size
int64 1
8.55M
| source_encoding
stringclasses 11
values | md5
stringlengths 32
32
| text
stringlengths 0
8.49M
|
---|---|---|---|---|---|---|---|---|
google
|
chromium
|
initlist23
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/initlist23.C
| 195 |
utf_8
|
8d226b5ec13a739254991dee1a2a148e
|
// { dg-options "-std=c++0x" }
#include <initializer_list>
struct A
{
A& operator=(int i);
A& operator=(std::initializer_list<int> l) { return *this; }
};
int main()
{
A a;
a = { };
}
|
google
|
chromium
|
variadic78
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic78.C
| 387 |
utf_8
|
2ff11a0463d3e57479047361f5d7b46f
|
// PR c++/33496
// { dg-do compile }
// { dg-options "-std=gnu++0x" }
template<int M, int N> struct pair
{
int i, j;
pair () : i (M), j (N) {}
};
template<int... M> struct S
{
template<int... N> static int *foo ()
{
static int x[] = { (M + N)... }; // { dg-error "mismatched argument pack lengths" }
return x;
}
};
int *bar ()
{
return S<0, 1, 2>::foo<0, 1> ();
}
|
google
|
chromium
|
bracket2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/bracket2.C
| 343 |
utf_8
|
11a41d54cdbb269d3b249a115afe87b3
|
// { dg-do "compile" }
// { dg-options "-std=gnu++0x" }
template<int i> class X { /* ... */ };
X< 1>2 > x1; // // { dg-error "numeric constant" }
X<(1>2)> x2; // Okay.
template<class T> class Y { /* ... */ };
Y<X<1>> x3; // Okay, same as "Y<X<1> > x3;".
Y<X<6>>1>> x4; // { dg-error "numeric constant" }
Y<X<(6>>1)>> x5; // Okay
|
google
|
chromium
|
variadic-init
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic-init.C
| 934 |
utf_8
|
e27f5d2cf1ffacc9b03605f63974cadf
|
// { dg-do run }
// { dg-options "-std=gnu++0x" }
// PR c++/33510
#define SIZE_FROM_CTOR
extern "C" void abort ();
template<int M, int N> struct pair
{
int i, j;
pair () : i (M), j (N) {}
};
template<int... M> struct S
{
template<int... N> static int *foo ()
{
#ifdef SIZE_FROM_CTOR
static int x[] = { (M + N)..., -1 };
#else
static int x[1 + sizeof... N] = { (M + N)..., -1 };
#endif
return x;
}
};
template<typename... M> struct R
{
template<typename... N> static int *foo ()
{
#ifdef SIZE_FROM_CTOR
static int x[] = { (sizeof(M) + sizeof(N))..., -1 };
#else
static int x[1 + sizeof... N] = { (sizeof(M) + sizeof(N))..., -1 };
#endif
return x;
}
};
int *bar ()
{
return S<0, 1, 2>::foo<0, 1, 2> ();
}
int *baz ()
{
return R<char, short, int>::foo<float, double, long> ();
}
int main ()
{
int *p = bar ();
if (p[0] != 0 || p[1] != 2 || p[2] != 4 || p[3] != -1)
abort ();
}
|
google
|
chromium
|
variadic-rref
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic-rref.C
| 543 |
utf_8
|
c7998c4ac21872f368cab23c1418557f
|
// { dg-options "-std=c++0x" }
// PR c++/33939
template<typename T>
struct refs_only;
template<typename T>
struct refs_only<T &>
{};
template<typename T>
refs_only<T> foo( T && t)
{
return refs_only<T>();
}
template<typename... T>
struct va_refs_only;
template<typename T>
struct va_refs_only<T>
: refs_only<T>
{};
template<typename... T>
va_refs_only<T...> bar( T &&... t)
{
return va_refs_only<T...>();
}
int main()
{
int j = 0;
foo(j);
bar(j); // error: invalid use of incomplete type 'struct refs_only<int>'
}
|
google
|
chromium
|
vt-37737-2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-37737-2.C
| 202 |
utf_8
|
8bc89288f021b015995e462427a20d65
|
// { dg-options "-std=c++0x" }
template<class U, class... T>
void f()
{
f<T...>(); // { dg-error "no matching" }
}
template<>
void f() { } // { dg-error "template-id" }
int main()
{
f<char>();
}
|
google
|
chromium
|
variadic56
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic56.C
| 448 |
utf_8
|
e40e17dbd8292e2f422b8b91bbee4dd0
|
// { dg-options "-std=gnu++0x" }
template<typename... Elements>
struct tuple { };
template<typename T, typename... Elements>
struct tuple<T, Elements...> {
int foo();
};
template<typename T, typename... Elements>
struct tuple<T*, Elements...> {
int bar();
};
template<typename T, typename... Elements>
int tuple<T, Elements...>::foo() { return 0; }
template<typename T, typename... Elements>
int tuple<T*, Elements...>::bar() { return 0; }
|
google
|
chromium
|
decltype5
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype5.C
| 735 |
utf_8
|
9a0d270d04b89211fe181dede77f30d9
|
// { dg-do "compile" }
// { dg-options "-std=gnu++0x" }
template<typename T, typename U>
struct is_same
{
static const bool value = false;
};
template<typename T>
struct is_same<T, T>
{
static const bool value = true;
};
#define CHECK_DECLTYPE(DECLTYPE,RESULT) \
static_assert(is_same< DECLTYPE , RESULT >::value, #RESULT)
template<typename F> F create_a();
template<typename F, typename T1>
decltype(create_a<F&>()(create_a<const T1&>())) forward(F f, const T1& a1)
{
return f(a1);
}
struct identity {
template<typename T>
const T& operator()(const T& x) { return x; }
};
identity id;
int i;
float f;
CHECK_DECLTYPE(decltype(forward(id, i)), const int&);
CHECK_DECLTYPE(decltype(forward(id, f)), const float&);
|
google
|
chromium
|
variadic27
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic27.C
| 620 |
utf_8
|
e1c1c803b8b835b458fc646fcad89176
|
// { dg-options "-std=gnu++0x" }
template<typename Signature>
struct function_traits;
template<typename R, typename... ArgTypes>
struct function_traits<R(ArgTypes...)> {
typedef R result_type;
};
template<typename T, typename U>
struct same_type {
static const bool value = false;
};
template<typename T>
struct same_type<T, T> {
static const bool value = true;
};
int a0[same_type<function_traits<int()>::result_type, int>::value? 1 : -1];
int a1[same_type<function_traits<int(float)>::result_type, int>::value? 1 : -1];
int a2[same_type<function_traits<int(double, char)>::result_type, int>::value? 1 : -1];
|
google
|
chromium
|
pr34054
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr34054.C
| 137 |
utf_8
|
bbcc78c712a69424c96cae056e31513a
|
// PR c++/34054
// { dg-do compile }
// { dg-options "-std=c++0x" }
template<typename... T> T foo() {} // { dg-error "not expanded|T" }
|
google
|
chromium
|
decltype-refbug
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype-refbug.C
| 317 |
utf_8
|
5be5466d65fc05f7bff75fd042614d66
|
// { dg-options "-std=c++0x" }
// PR c++/33045
int && f ();
template<typename T, typename U>
struct is_same
{
static const bool value = false;
};
template<typename T>
struct is_same<T, T>
{
static const bool value = true;
};
static_assert(is_same<decltype(f()), int&&>::value, "decltype of rvalue reference");
|
google
|
chromium
|
rv9p
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv9p.C
| 276 |
utf_8
|
b873eb6dd4e6daa5c9f634ffe8e7b919
|
// PR c++/36744
// { dg-options "-std=c++0x" }
// { dg-do run }
struct S
{
S(): i(2) {}
S(S const&s): i(s.i) {}
int i;
};
void f(S x) { x.i = 0; }
extern "C" void abort (void);
int main()
{
S y;
f(static_cast<S&&>(y));
if (y.i != 2)
abort ();
return 0;
}
|
google
|
chromium
|
variadic48
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic48.C
| 173 |
utf_8
|
a57a0da544372c92597786efed9659fd
|
// { dg-options "-std=gnu++0x" }
template<typename T, typename... Args>
int& f(const T&, Args...);
template<typename T>
float& f(const T&);
float& g() {
return f(17);
}
|
google
|
chromium
|
variadic72
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic72.C
| 243 |
utf_8
|
abcb3f8130d4cb79480994b5d80f646c
|
// { dg-options "-std=gnu++0x" }
struct A {};
struct B {};
struct C {};
template<typename... Mixins>
struct mixed_up : public Mixins...
{
};
void fA(A);
void fB(B);
void g()
{
mixed_up<A, B, C> m;
fA(m);
fB(m);
fC(m);
}
|
google
|
chromium
|
decltype8
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype8.C
| 370 |
utf_8
|
bbdff105c665351973aaa6a25eaa0940
|
// PR c++/34267
// { dg-do compile }
struct A {};
__decltype (A); // { dg-error "must be an expression" }
template<int> struct B
{
__decltype (A); // { dg-error "must be an expression" }
__decltype (~A); // { dg-error "must be an expression" }
__decltype (B); // { dg-error "must be an expression" }
__decltype (~B); // { dg-error "must be an expression" }
};
|
google
|
chromium
|
variadic9
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic9.C
| 810 |
utf_8
|
39a4617d5385099583397f9c019a4b4c
|
// { dg-options "-std=gnu++0x" }
template<typename T1, typename T2>
struct pair {};
template<typename... Args>
struct tuple {
static const int value = 0;
};
template<>
struct tuple<pair<int, float> > {
static const int value = 1;
};
template<typename U>
struct tuple<pair<int, U> > {
static const int value = 2;
};
template<typename T, typename U>
struct tuple<pair<T, U>, pair<T, U> > {
static const int value = 3;
};
template<typename... Outer>
struct X {
template<typename... Inner>
struct Y
{
typedef tuple<pair<Outer, Inner>...> type;
};
};
int a0[X<int, double>::Y<short, char>::type::value == 0? 1 : -1];
int a1[X<int>::Y<float>::type::value == 1? 1 : -1];
int a2[X<int>::Y<double>::type::value == 2? 1 : -1];
int a3[X<int, int>::Y<double, double>::type::value == 3? 1 : -1];
|
google
|
chromium
|
variadic-ex3
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic-ex3.C
| 258 |
utf_8
|
39f75b28d44e8689996e60919723e838
|
// { dg-options "-std=gnu++0x" }
template<class X, class Y, class... Z> X f(Y);
void g()
{
int i = f<int>(5.6);
int j = f(5.6); // { dg-error "no matching" }
f<void>(f<int, bool>);
f<void>(f<int>); // { dg-error "no matching" }
}
|
google
|
chromium
|
pr31445
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr31445.C
| 164 |
utf_8
|
addbcb87d162dffbefde94ee17a3d0e7
|
// { dg-options "-std=gnu++0x" }
template <typename... T> struct A
{
void foo(T...);
A(T... t) { foo(t); } // { dg-error "parameter packs|t" }
};
A<int> a(0);
|
google
|
chromium
|
variadic8
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic8.C
| 451 |
utf_8
|
d0dc500406e92f2a7bf9d8ec9c78c329
|
// { dg-options "-std=gnu++0x" }
template<typename... Args>
struct tuple_base {
static const int value = 0;
};
template<>
struct tuple_base<int*>
{
static const int value = 1;
};
template<typename T>
struct tuple_base<T*>
{
static const int value = 2;
};
template<typename... Args>
struct tuple_of_pointers : tuple_base<Args*...> { };
int a1[tuple_of_pointers<int>::value == 1? 1 : -1];
int a2[tuple_of_pointers<float>::value == 2? 1 : -1];
|
google
|
chromium
|
variadic70
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic70.C
| 407 |
utf_8
|
10204de9c91628ca99f21bf18b22b06d
|
// { dg-do "run" }
// { dg-options "-std=gnu++0x" }
template <typename T, T... Args> struct bomb;
template <typename T>
struct bomb<T> {
static const T value = 0;
};
template <typename T, T v, T... Args>
struct bomb<T, v, Args...> {
static const T value = v + bomb<T, Args...>::value;
};
extern "C" void abort();
int main() {
bomb<int, 1, 2, 3, 4> b;
if (b.value != 10)
abort();
return 0;
}
|
google
|
chromium
|
overload-conv-1
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/overload-conv-1.C
| 288 |
utf_8
|
3a17cd678756b6b530cc9d447f967678
|
// { dg-options "--std=c++0x" }
// { dg-do link }
struct S {};
struct T
{
operator S() { return S(); }
};
struct U
{
operator S&() { return *static_cast<S*>(0); }
};
void f(const S&);
void f(S&&) {}
void g(const S&) {}
void g(S&&);
int main()
{
T t;
f(t);
U u;
g(u);
}
|
google
|
chromium
|
auto7
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/auto7.C
| 285 |
utf_8
|
8556d6750a30e8542f3922be9b89a92e
|
// PR c++/37965
// Negative test for auto
// { dg-options "-std=c++0x" }
auto i = 6;
auto j; // { dg-error "has no initializer" }
template<int> struct A
{
static auto k = 7;
static auto l; // { dg-error "has no initializer" }
auto m; // { dg-error "has no initializer" }
};
|
google
|
chromium
|
pr33955
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr33955.C
| 770 |
utf_8
|
df1e87feaf65676ae83648e44c557581
|
// { dg-options "-std=c++0x" }
template<typename T>
struct uncvref
{
typedef T type;
};
template<typename... Args>
struct args
{
static const int size = sizeof...(Args);
};
template<typename G, typename E, typename S, typename V, long GN = G::size, long EN = E::size>
struct apply_args;
template<typename... G, typename... E, typename S, typename V, long N>
struct apply_args<args<G...>, args<E...>, S, V, N, N>
{
typedef args<
typename G::template apply<typename uncvref<E>::type, S, V>::type...
> type;
};
struct or_
{
template<typename E, typename S, typename V>
struct apply {
typedef typename E::type type;
};
};
template<typename T>
struct identity
{
typedef T type;
};
apply_args<args<or_>, args<identity<int>>, float, double> a1;
|
google
|
chromium
|
variadic-mem_fn
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic-mem_fn.C
| 1,044 |
utf_8
|
532fc7f93bb229494e92be11cfcf8152
|
// { dg-options "-std=gnu++0x" }
// { dg-do "run" }
// A basic implementation of TR1's mem_fn using variadic teplates
#include <cassert>
template<typename R, typename Class, typename... Args>
class Mem_fn
{
public:
explicit Mem_fn(R (Class::*pmf)(Args...)) : pmf(pmf) { }
R operator()(Class& object, Args... args)
{
return (object.*pmf)(args...);
}
R operator()(Class* object, Args... args)
{
return (object->*pmf)(args...);
}
R (Class::*pmf)(Args...);
};
template<typename R, typename Class, typename... Args>
inline Mem_fn<R, Class, Args...>
mem_fn(R (Class::* pmf)(Args...))
{
return Mem_fn<R, Class, Args...>(pmf);
}
class X {
public:
int negate(int x) { return -x; }
int plus(int x, int y) { return x + y; }
};
int main()
{
X x;
X* xp = &x;
assert(mem_fn(&X::negate)(x, 17) == -17);
assert(mem_fn(&X::negate)(xp, 17) == -17);
assert(mem_fn(&X::plus)(x, 17, 25) == 42);
assert(mem_fn(&X::plus)(xp, 17, 25) == 42);
return 0;
}
|
google
|
chromium
|
initlist3
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/initlist3.C
| 143 |
utf_8
|
ebf07d4ed58e4156777e047923969c63
|
// { dg-options "-std=c++0x" }
#include <initializer_list>
template <class T> void f(std::initializer_list<T>);
void g()
{
f({1,2,3});
}
|
google
|
chromium
|
auto10
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/auto10.C
| 318 |
utf_8
|
48f61f18a7cb3cb48d7aa3d0ca0e9653
|
// Positive test for auto
// { dg-do run }
// { dg-options "-std=c++0x" }
#include <typeinfo>
extern "C" void abort();
int main()
{
if (auto i = 42L)
{
if (typeid (i) != typeid (long int))
abort ();
}
while (auto i = 1)
{
if (typeid (i) != typeid (int))
abort ();
break;
}
}
|
google
|
chromium
|
variadic88
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic88.C
| 334 |
utf_8
|
32cce31ef2c89f2acbe149f22af0fd89
|
// { dg-options "-std=c++0x" }
template<template<typename...> class TT>
TT<int, float, double> foo(TT<int, float>)
{
return TT<int, float, double>();
}
template<typename T>
int& foo(T)
{
static int i = 0; return i;
}
template<typename T, typename U>
struct pair {};
void bar()
{
pair<int, float> p;
int& i = foo(p);
}
|
google
|
chromium
|
decltype-38655
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype-38655.C
| 101 |
utf_8
|
51bee11248b9515ebb07cbd465c4fc47
|
// PR c++/38655
// { dg-options "" }
__decltype(0r)* p = 1; // { dg-error "not supported|invalid" }
|
google
|
chromium
|
variadic17
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic17.C
| 693 |
utf_8
|
3053d79335fc919b210a3cc63f124ff4
|
// { dg-options "-std=gnu++0x" }
template<typename R, typename... ArgTypes>
struct make_function_type
{
typedef R type(const ArgTypes&......);
};
template<typename T, typename U>
struct is_same {
static const bool value = false;
};
template<typename T>
struct is_same<T, T> {
static const bool value = true;
};
int a0[is_same<make_function_type<int>::type, int(...)>::value? 1 : -1];
int a1[is_same<make_function_type<int, float>::type, int(const float&...)>::value? 1 : -1];
int a2[is_same<make_function_type<int, float>::type, int(const float&,...)>::value? 1 : -1];
int a3[is_same<make_function_type<int, float, double>::type, int(const float&, double const&...)>::value? 1 : -1];
|
google
|
chromium
|
defaulted8
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/defaulted8.C
| 189 |
utf_8
|
e4eda3d1136f1741945b988346e3fedf
|
// PR c++/38649
// { dg-options "-std=c++0x" }
struct A
{
A(...) = default; // { dg-error "cannot be defaulted" }
A(const A&, ...) = default; // { dg-error "cannot be defaulted" }
};
|
google
|
chromium
|
bracket4
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/bracket4.C
| 447 |
utf_8
|
36e9e29872771c502d6bd3626d7e167f
|
// { dg-do "compile" }
// { dg-options "-std=c++0x" }
template<typename T>
struct vector {
};
struct X {
template<typename T>
struct tmpl {
operator T() const;
};
};
template<typename T>
void g()
{
T::template tmpl<vector<int>>() + 2;
}
template<typename T>
void operator+(vector<T>, int);
void f()
{
vector<vector<int>>() + 2;
}
// PR c++/36460
template <class a>
class A {};
template <class b>
class B {};
A<B<void()>> x;
|
google
|
chromium
|
decltype16
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype16.C
| 338 |
utf_8
|
c00e5bacd6ac200e6550fc2d6d4ac73e
|
// PR c++/39070
// { dg-options "-std=c++0x" }
template<typename X> struct junk {
template<typename Z> static Z y();
template<typename Y> static int test(...);
template<typename Y> static char test(decltype(y<Y>())*);
static int const value=sizeof(test<X>(0));
};
typedef char type[junk<int>::value==sizeof(char) ? 1 : -1];
|
google
|
chromium
|
vt-34754
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-34754.C
| 182 |
utf_8
|
1cfb3c958fc83ba360a143ded32ea720
|
// { dg-options "-std=c++0x" }
template<template<int> class... T> struct A
{
void foo(T<0>); // { dg-error "not expanded|T" }
void bar(T<0>); // { dg-error "not expanded|T" }
};
|
google
|
chromium
|
variadic90
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic90.C
| 150 |
utf_8
|
f80347db0d73cb0924ddb0b6f5e9f810
|
// { dg-options "-std=c++0x" }
template<template<typename...> class TT>
struct X { };
template<typename T, typename U> struct pair { };
X<pair> x;
|
google
|
chromium
|
temp-constructor-bug
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/temp-constructor-bug.C
| 118 |
utf_8
|
fc6f2e96c9f8ec014c9c4aa1c6219117
|
// { dg-options "--std=c++0x" }
struct S { };
struct T
{
S s;
};
void f(T const &);
void g()
{
f((T){S()});
}
|
google
|
chromium
|
rv1n
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv1n.C
| 4,541 |
utf_8
|
515c22f2491f2538ef1856d4849193c8
|
// I, Howard Hinnant, hereby place this code in the public domain.
// Test overlaod resolution among referece types
// { dg-do compile }
// { dg-options "-std=c++0x" }
template <bool> struct sa;
template <> struct sa<true> {};
struct one {char x[1];};
struct two {char x[2];};
struct three {char x[3];};
struct four {char x[4];};
struct five {char x[5];};
struct six {char x[6];};
struct seven {char x[7];};
struct eight {char x[8];};
struct A
{
A();
A(const volatile A&&);
};
A source();
const A c_source();
volatile A v_source();
const volatile A cv_source();
// 1 at a time
one sink_1_1( A&); // { dg-error "" }
int test1_1()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_1(ca); // { dg-error "invalid initialization" }
sink_1_1(va); // { dg-error "invalid initialization" }
sink_1_1(cva); // { dg-error "invalid initialization" }
sink_1_1(source()); // { dg-error "invalid initialization" }
sink_1_1(c_source()); // { dg-error "invalid initialization" }
sink_1_1(v_source()); // { dg-error "invalid initialization" }
sink_1_1(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
two sink_1_2(const A&); // { dg-error "" }
int test1_2()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_2(va); // { dg-error "invalid initialization" }
sink_1_2(cva); // { dg-error "invalid initialization" }
sink_1_2(v_source()); // { dg-error "invalid initialization" }
sink_1_2(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
three sink_1_3(volatile A&); // { dg-error "" }
int test1_3()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_3(ca); // { dg-error "invalid initialization" }
sink_1_3(cva); // { dg-error "invalid initialization" }
sink_1_3(source()); // { dg-error "invalid initialization" }
sink_1_3(c_source()); // { dg-error "invalid initialization" }
sink_1_3(v_source()); // { dg-error "invalid initialization" }
sink_1_3(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
four sink_1_4(const volatile A&); // { dg-error "" }
int test1_4()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_4(source()); // { dg-error "invalid initialization" }
sink_1_4(c_source()); // { dg-error "invalid initialization" }
sink_1_4(v_source()); // { dg-error "invalid initialization" }
sink_1_4(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
five sink_1_5( A&&); // { dg-error "" }
int test1_5()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_5(ca); // { dg-error "invalid initialization" }
sink_1_5(va); // { dg-error "invalid initialization" }
sink_1_5(cva); // { dg-error "invalid initialization" }
sink_1_5(c_source()); // { dg-error "invalid initialization" }
sink_1_5(v_source()); // { dg-error "invalid initialization" }
sink_1_5(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
six sink_1_6(const A&&); // { dg-error "" }
int test1_6()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_6(va); // { dg-error "invalid initialization" }
sink_1_6(cva); // { dg-error "invalid initialization" }
sink_1_6(v_source()); // { dg-error "invalid initialization" }
sink_1_6(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
seven sink_1_7(volatile A&&); // { dg-error "" }
int test1_7()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_1_7(ca); // { dg-error "invalid initialization" }
sink_1_7(cva); // { dg-error "invalid initialization" }
sink_1_7(c_source()); // { dg-error "invalid initialization" }
sink_1_7(cv_source()); // { dg-error "invalid initialization" }
return 0;
}
int main()
{
return test1_1() + test1_2() + test1_3() + test1_5() +
test1_6() + test1_7();
}
|
google
|
chromium
|
pr31431
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr31431.C
| 146 |
utf_8
|
7eb11551d854e0c87cc2b229bf388094
|
// { dg-options "-std=gnu++0x" }
template<typename..., typename> void foo();
void bar()
{
foo<int>(); // { dg-error "no matching function" }
}
|
google
|
chromium
|
variadic73
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic73.C
| 491 |
utf_8
|
7025864b5e6a3ee61f7bf140a97d6b90
|
// { dg-do "run" }
// { dg-options "-std=gnu++0x" }
struct A {};
struct B {};
struct C {};
template<typename... Exceptions> void f(int idx) throw(Exceptions...) {
if (idx == 0) throw A();
else if (idx == 1) throw B();
else if (idx == 2) throw C();
}
extern "C" void abort();
int main()
{
try {
f<A, B, C>(0);
abort();
} catch (A) {
}
try {
f<A, B, C>(1);
abort();
} catch (B) {
}
try {
f<A, B, C>(2);
abort();
}
return 0;
}
|
google
|
chromium
|
rv2n
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv2n.C
| 11,047 |
utf_8
|
2e4634a4536f9a33b503f1c17c37e809
|
// I, Howard Hinnant, hereby place this code in the public domain.
// Test overlaod resolution among referece types
// { dg-do compile }
// { dg-options "-std=c++0x" }
template <bool> struct sa;
template <> struct sa<true> {};
struct one {char x[1];};
struct two {char x[2];};
struct three {char x[3];};
struct four {char x[4];};
struct five {char x[5];};
struct six {char x[6];};
struct seven {char x[7];};
struct eight {char x[8];};
struct A
{
A();
A(const volatile A&&);
};
A source();
const A c_source();
volatile A v_source();
const volatile A cv_source();
// 2 at a time
one sink_2_12( A&); // { dg-message "candidates" }
two sink_2_12(const A&); // { dg-message "note" }
int test2_12()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_12(va); // { dg-error "no match" }
sink_2_12(cva); // { dg-error "no match" }
sink_2_12(v_source()); // { dg-error "no match" }
sink_2_12(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_2_13( A&); // { dg-message "candidates" }
three sink_2_13(volatile A&); // { dg-message "note" }
int test2_13()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_13(ca); // { dg-error "no match" }
sink_2_13(cva); // { dg-error "no match" }
sink_2_13(source()); // { dg-error "no match" }
sink_2_13(c_source()); // { dg-error "no match" }
sink_2_13(v_source()); // { dg-error "no match" }
sink_2_13(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_2_14( A&); // { dg-message "candidates" }
four sink_2_14(const volatile A&); // { dg-message "note" }
int test2_14()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_14(source()); // { dg-error "no match" }
sink_2_14(c_source()); // { dg-error "no match" }
sink_2_14(v_source()); // { dg-error "no match" }
sink_2_14(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_2_15( A&); // { dg-message "candidates" }
five sink_2_15( A&&); // { dg-message "note" }
int test2_15()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_15(ca); // { dg-error "no match" }
sink_2_15(va); // { dg-error "no match" }
sink_2_15(cva); // { dg-error "no match" }
sink_2_15(c_source()); // { dg-error "no match" }
sink_2_15(v_source()); // { dg-error "no match" }
sink_2_15(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_2_16( A&); // { dg-message "candidates" }
six sink_2_16(const A&&); // { dg-message "note" }
int test2_16()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_16(va); // { dg-error "no match" }
sink_2_16(cva); // { dg-error "no match" }
sink_2_16(v_source()); // { dg-error "no match" }
sink_2_16(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_2_17( A&); // { dg-message "candidates" }
seven sink_2_17(volatile A&&); // { dg-message "note" }
int test2_17()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_17(ca); // { dg-error "no match" }
sink_2_17(cva); // { dg-error "no match" }
sink_2_17(c_source()); // { dg-error "no match" }
sink_2_17(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_2_23(const A&); // { dg-message "candidates" }
three sink_2_23(volatile A&); // { dg-message "note" }
int test2_23()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_23(a); // { dg-error "ambiguous" }
sink_2_23(cva); // { dg-error "no match" }
sink_2_23(v_source()); // { dg-error "no match" }
sink_2_23(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_2_24(const A&); // { dg-message "candidates" }
four sink_2_24(const volatile A&); // { dg-message "note" }
int test2_24()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_24(v_source()); // { dg-error "no match" }
sink_2_24(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_2_34(volatile A&); // { dg-message "candidate" }
four sink_2_34(const volatile A&); // { dg-message "note" }
int test2_34()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_34(source()); // { dg-error "no match" }
sink_2_34(c_source()); // { dg-error "no match" }
sink_2_34(v_source()); // { dg-error "no match" }
sink_2_34(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_2_25(const A&); // { dg-message "candidate" }
five sink_2_25( A&&); // { dg-message "note" }
int test2_25()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_25(va); // { dg-error "no match" }
sink_2_25(cva); // { dg-error "no match" }
sink_2_25(v_source()); // { dg-error "no match" }
sink_2_25(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_2_26(const A&); // { dg-message "candidate" }
six sink_2_26(const A&&); // { dg-message "note" }
int test2_26()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_26(va); // { dg-error "no match" }
sink_2_26(cva); // { dg-error "no match" }
sink_2_26(v_source()); // { dg-error "no match" }
sink_2_26(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_2_27(const A&); // { dg-message "candidate" }
seven sink_2_27(volatile A&&); // { dg-message "note" }
int test2_27()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_27(cva); // { dg-error "no match" }
sink_2_27(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_2_35(volatile A&); // { dg-message "candidate" }
five sink_2_35( A&&); // { dg-message "note" }
int test2_35()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_35(ca); // { dg-error "no match" }
sink_2_35(cva); // { dg-error "no match" }
sink_2_35(c_source()); // { dg-error "no match" }
sink_2_35(v_source()); // { dg-error "no match" }
sink_2_35(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_2_36(volatile A&); // { dg-message "candidate" }
six sink_2_36(const A&&); // { dg-message "note" }
int test2_36()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_36(cva); // { dg-error "no match" }
sink_2_36(v_source()); // { dg-error "no match" }
sink_2_36(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_2_37(volatile A&); // { dg-message "candidate" }
seven sink_2_37(volatile A&&); // { dg-message "note" }
int test2_37()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_37(ca); // { dg-error "no match" }
sink_2_37(cva); // { dg-error "no match" }
sink_2_37(c_source()); // { dg-error "no match" }
sink_2_37(cv_source()); // { dg-error "no match" }
return 0;
}
four sink_2_45(const volatile A&); // { dg-message "candidate" }
five sink_2_45( A&&); // { dg-message "note" }
int test2_45()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_45(c_source()); // { dg-error "no match" }
sink_2_45(v_source()); // { dg-error "no match" }
sink_2_45(cv_source()); // { dg-error "no match" }
return 0;
}
four sink_2_46(const volatile A&); // { dg-message "candidate" }
six sink_2_46(const A&&); // { dg-message "note" }
int test2_46()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_46(v_source()); // { dg-error "no match" }
sink_2_46(cv_source()); // { dg-error "no match" }
return 0;
}
four sink_2_47(const volatile A&); // { dg-message "candidate" }
seven sink_2_47(volatile A&&); // { dg-message "note" }
int test2_47()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_47(c_source()); // { dg-error "no match" }
sink_2_47(cv_source()); // { dg-error "no match" }
return 0;
}
five sink_2_56( A&&); // { dg-message "candidate" }
six sink_2_56(const A&&); // { dg-message "note" }
int test2_56()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_56(va); // { dg-error "no match" }
sink_2_56(cva); // { dg-error "no match" }
sink_2_56(v_source()); // { dg-error "no match" }
sink_2_56(cv_source()); // { dg-error "no match" }
return 0;
}
five sink_2_57( A&&); // { dg-message "candidate" }
seven sink_2_57(volatile A&&); // { dg-message "note" }
int test2_57()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_57(ca); // { dg-error "no match" }
sink_2_57(cva); // { dg-error "no match" }
sink_2_57(c_source()); // { dg-error "no match" }
sink_2_57(cv_source()); // { dg-error "no match" }
return 0;
}
six sink_2_67(const A&&); // { dg-message "candidate" }
seven sink_2_67(volatile A&&); // { dg-message "note" }
int test2_67()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_2_67(a); // { dg-error "ambiguous" }
sink_2_67(cva); // { dg-error "no match" }
sink_2_67(source()); // { dg-error "ambiguous" }
sink_2_67(cv_source()); // { dg-error "no match" }
return 0;
}
int main()
{
return test2_12() + test2_13() + test2_15() + test2_16() +
test2_17() + test2_23() + test2_25() + test2_26() +
test2_27() + test2_35() + test2_36() + test2_37() +
test2_56() + test2_57() + test2_67();
}
|
google
|
chromium
|
pr31438
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr31438.C
| 237 |
utf_8
|
825669c06b592081ee46c7b3f2839a43
|
// { dg-options "-std=gnu++0x" }
template<typename> struct A;
template<typename T, typename... U> struct A<T(U)> // { dg-error "parameter packs|U" }
{
template<typename X> A(X);
};
A<void(int)> a(0); // { dg-error "incomplete type" }
|
google
|
chromium
|
auto11
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/auto11.C
| 190 |
utf_8
|
fc9eb91216b67d1f8b1342c8b7039163
|
// PR c++/38256
// { dg-options "-std=c++0x" }
template<int> struct A
{
template<typename T> operator T();
};
void foo()
{
A<0>().operator auto(); // { dg-error "auto.*conversion" }
}
|
google
|
chromium
|
variadic2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic2.C
| 503 |
utf_8
|
be09491ac08d1c7bda2bd004c7a559e9
|
// { dg-options "-std=gnu++0x" }
template<typename... Args = int> // { dg-error "default argument" }
class tuple2;
template<typename... = int> // { dg-error "default argument" }
class tuple3;
template<typename T1, typename T2, typename... Rest>
struct two_or_more {}; // { dg-error "provided for" }
typedef two_or_more<int> bad; // { dg-error "2 or more" }
// { dg-error "invalid type" "" { target *-*-* } 11 }
void f()
{
two_or_more<int, float> z = 5; // { dg-error "two_or_more<int, float>" }
}
|
google
|
chromium
|
variadic23
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic23.C
| 561 |
utf_8
|
7615032e452443ba81dd6860d86129d7
|
// { dg-options "-std=gnu++0x" }
template<typename T, int... Dims>
struct array {
static const int value = 0;
};
template<>
struct array<int, 17> {
static const int value = 1;
};
template<int... Dims>
struct array<float, 1, Dims...> {
static const int value = 2;
};
template<typename T, int... Dims>
struct array<T, 1, Dims...> {
static const int value = 3;
};
int a0[array<int>::value == 0? 1 : -1];
int a1[array<int, 17>::value == 1? 1 : -1];
int a2[array<float, 1, 2, 3>::value == 2? 1 : -1];
int a3[array<double, 1, 2, 3>::value == 3? 1 : -1];
|
google
|
chromium
|
variadic42
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic42.C
| 282 |
utf_8
|
882edd920ddef1a6fbd93d4332151817
|
// { dg-options "-std=gnu++0x" }
// { dg-do compile }
template<typename... Args>
void f(Args...) { }
void g()
{
f<int*, float*, double*>(0, 0, 0);
f<int*>(0,0,0);
}
// { dg-final { scan-assembler "_Z1fIIPiPfPdEEvDpT_" } }
// { dg-final { scan-assembler "_Z1fIIPiiiEEvDpT_" } }
|
google
|
chromium
|
bracket1
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/bracket1.C
| 251 |
utf_8
|
8de576619233b452b8827b9ad733a5fd
|
// { dg-do "compile" }
// { dg-options "-std=gnu++0x" }
template<typename T>
struct list {};
template<typename T>
struct vector {
operator T() const;
};
void f()
{
vector<vector<int>> v;
const vector<int> vi = static_cast<vector<int>>(v);
}
|
google
|
chromium
|
decltype7
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype7.C
| 267 |
utf_8
|
c3626f3b26fbb53bd234a4e39649b63f
|
// PR c++/34268
// { dg-do compile }
struct A
{
__decltype (A); // { dg-error "must be an expression" }
__decltype (~A); // { dg-error "must be an expression" }
};
struct B
{
__typeof__ (B);
__typeof__ (~B); // { dg-error "expected primary-expression" }
};
|
google
|
chromium
|
pr32125
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr32125.C
| 153 |
utf_8
|
50b3b289f7f997c655ffb07822094555
|
// { dg-options "-std=c++0x" }
template<typename...> struct A;
template<typename...T> struct A<T*> // { dg-error "not expanded|T" }
{
A();
A(T);
};
|
google
|
chromium
|
variadic-crash2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic-crash2.C
| 377 |
utf_8
|
554a7c17abf02e2bda69bbb7d98c12dd
|
// Origin: PR c++/39637
// { dg-options "-std=gnu++0x" }
// { dg-do "compile" }
template<class... Types>
void
f(Types...)
{
enum {e = sizeof(Types)}; // { dg-error "parameter packs not expanded with '...'" }
enum {e1 = sizeof...(Types)};
}
int
main()
{
f(0);
}
// { dg-message "note" "Types" { target *-*-* } 10 }
|
google
|
chromium
|
trailing2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/trailing2.C
| 469 |
utf_8
|
dff8e484f5ebc462a610d96381bb6352
|
// PR c++/37967
// Negative test for auto
// { dg-options "-std=c++0x" }
auto f1 () -> int;
auto f2 (); // { dg-error "without late return type" }
int f3 () -> int; // { dg-error "late return type" }
auto *f4 () -> int; // { dg-error "late return type" }
struct A
{
auto f5 () const -> int;
auto f6 (); // { dg-error "without late return type" }
int f7 () -> int; // { dg-error "late return type" }
auto *f8 () -> int; // { dg-error "late return type" }
};
|
google
|
chromium
|
decltype11
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype11.C
| 130 |
utf_8
|
b1ca5344811760f6e82c858f672bd0f6
|
// PR c++/35316
// { dg-options "-std=c++0x" }
template<int> struct A
{
int i : 2;
void foo()
{
decltype(i) j;
}
};
|
google
|
chromium
|
variadic44
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic44.C
| 232 |
utf_8
|
e9bb2fef020609c3ee50141c2338a550
|
// { dg-options "-std=gnu++0x" }
// { dg-do compile }
template<typename... Args>
int f(const Args&...);
template<typename T> void g(T) { }
void h()
{
g(&f<int, float>);
}
// { dg-final { scan-assembler "_Z1gIPFiRKiRKfEEvT_"} }
|
google
|
chromium
|
variadic21
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic21.C
| 149 |
utf_8
|
57823f63ca045ff8b8c15796278b39d1
|
// { dg-options "-std=gnu++0x" }
template<typename T, int... Dims>
struct array { };
array<int> a0;
array<int, 1> a1;
array<int, 1, 2, 3, 4> a1234;
|
google
|
chromium
|
trailing5
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/trailing5.C
| 178 |
utf_8
|
d0d8f484e5d5d333ca0101b985fc1397
|
// PR c++/38798, DR 770
// { dg-options -std=c++0x }
struct A {};
auto foo() -> struct A {}
enum B {};
auto bar() -> enum B {}
auto baz() -> struct C {} {} // { dg-error "" }
|
google
|
chromium
|
static_assert2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/static_assert2.C
| 726 |
utf_8
|
8cbc91f4f007ae34557f6cc27a860398
|
// { dg-options "-std=c++0x" }
template<int I>
struct accept_evens {
static_assert( I % 2 == 0, "I must be an even number"); // { dg-error "even number" }
};
template<int I>
struct accept_evens_ok {
static_assert( I % 2 == 0, "I must be an even number");
};
template<int I>
void accept_odds() {
static_assert( I % 2 == 1, "I must be an odd number"); // { dg-error "odd number" }
}
template<int I>
void accept_odds_ok() {
static_assert( I % 2 == 1, "I must be an odd number");
}
void f()
{
accept_odds<1>();
accept_odds<2>();
accept_odds<3>();
accept_odds_ok<5>();
accept_odds_ok<7>();
}
accept_evens<0> ok0;
accept_evens<1> error1;
accept_evens<2> ok2;
accept_evens_ok<4> ok4;
accept_evens_ok<6> ok6;
|
google
|
chromium
|
variadic65
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic65.C
| 323 |
utf_8
|
ffb178f32d948f5a5c9a54d7f36d2e2e
|
// { dg-options "-std=gnu++0x" }
struct unused;
template<typename T1 = unused, typename T2 = unused, typename T3 = unused,
typename T4 = unused, typename T5 = unused, typename T6 = unused>
struct tuple {};
template<typename... Args>
void foo(tuple<Args...>) { } // { dg-bogus "cannot expand" "" { xfail *-*-* } }
|
google
|
chromium
|
extern_template-3
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/extern_template-3.C
| 153 |
utf_8
|
a90d02344ce471556a85a9970c53f219
|
// PR c++/37256
// { dg-options "-O" }
template <typename T_>
struct B
{
T_ f();
};
extern template class B<int>;
void f()
{
B<int> t;
t.f();
}
|
google
|
chromium
|
variadic12
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic12.C
| 1,144 |
utf_8
|
55e99e1f39f96e8dde30908350a29ef4
|
// { dg-options "-std=gnu++0x" }
// A tuple type
template<typename... Args> struct tuple { };
// Determine if two types are the same
template<typename T, typename U>
struct is_same {
static const bool value = false;
};
template<typename T>
struct is_same<T, T> {
static const bool value = true;
};
// Append 'T' to the end of Tuple
template<typename T, typename Tuple>
struct append_to_tuple;
template<typename T, typename... Args>
struct append_to_tuple<T, tuple<Args...> > {
typedef tuple<Args..., T> type;
};
// Reverse a sequence of arguments (and return the result as a tuple)
template<typename... Args> struct reverse;
template<typename T, typename... Args>
struct reverse<T, Args...> {
typedef typename append_to_tuple<T, typename reverse<Args...>::type>::type
type;
};
template<>
struct reverse<> {
typedef tuple<> type;
};
int a0[is_same<reverse<>::type, tuple<> >::value? 1 : -1];
int a1[is_same<reverse<int>::type, tuple<int> >::value? 1 : -1];
int a2[is_same<reverse<char, int>::type, tuple<int, char> >::value? 1 : -1];
int a3[is_same<reverse<char, int, long>::type, tuple<long, int, char> >::value? 1 : -1];
|
google
|
chromium
|
decltype4
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype4.C
| 1,938 |
utf_8
|
859540e19d872366f2581f5571ade110
|
// { dg-do "compile" }
// { dg-options "-std=gnu++0x" }
template<typename T, typename U>
struct is_same
{
static const bool value = false;
};
template<typename T>
struct is_same<T, T>
{
static const bool value = true;
};
#define CHECK_DECLTYPE(DECLTYPE,RESULT) \
static_assert(is_same< DECLTYPE , RESULT >::value, #DECLTYPE " should be " #RESULT)
struct A {
int x;
int& y;
int foo(char);
int& bar() const;
};
CHECK_DECLTYPE(decltype(&A::x), int A::*);
decltype(&A::y) Ay; // { dg-error "cannot create pointer to reference member|invalid type" }
CHECK_DECLTYPE(decltype(&A::foo), int (A::*) (char));
CHECK_DECLTYPE(decltype(&A::bar), int& (A::*) () const);
CHECK_DECLTYPE(decltype("decltype"), const char(&)[9]);
CHECK_DECLTYPE(decltype(1), int);
int an_int = 5;
int& i = an_int;
const int j = an_int;
CHECK_DECLTYPE(decltype(i)&, int&);
CHECK_DECLTYPE(const decltype(j), const int);
int foo();
CHECK_DECLTYPE(decltype(foo()), int);
float& bar(int);
CHECK_DECLTYPE(decltype (bar(1)), float&);
const A bar();
CHECK_DECLTYPE(decltype (bar()), const A);
const A& bar2();
CHECK_DECLTYPE(decltype (bar2()), const A&);
void wibble() {
CHECK_DECLTYPE(decltype(1+2), int);
int* p;
CHECK_DECLTYPE(decltype(*p), int&);
int a[10];
CHECK_DECLTYPE(decltype(a[3]), int&);
int i; int& j = i;
CHECK_DECLTYPE(decltype (i = 5), int&);
CHECK_DECLTYPE(decltype (j = 5), int&);
CHECK_DECLTYPE(decltype (++i), int&);
CHECK_DECLTYPE(decltype (i++), int);
}
struct B {
int bit : 2;
const int cbit : 3;
void foo()
{
CHECK_DECLTYPE(decltype(bit), int);
CHECK_DECLTYPE(decltype((bit)), int&);
CHECK_DECLTYPE(decltype(cbit), const int);
CHECK_DECLTYPE(decltype((cbit)), const int&);
}
};
B b;
const B& bc = b;
CHECK_DECLTYPE(decltype(b.bit), int);
CHECK_DECLTYPE(decltype(bc.bit), int);
CHECK_DECLTYPE(decltype((b.bit)), int&);
CHECK_DECLTYPE(decltype((bc.bit)), const int&);
|
google
|
chromium
|
variadic58
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic58.C
| 380 |
utf_8
|
78d145f1910f8b120ca926a7f9715581
|
// { dg-options "-std=gnu++0x" }
#include <typeinfo>
template<typename... Args>
void foo(Args...) { }
template<typename... Args>
void bar(Args... args) {
foo(Args()...);
foo(args = args...);
foo(reinterpret_cast<void*>(&args)...);
foo(const_cast<const Args>(args)...);
foo(static_cast<void*>(&args)...);
foo(dynamic_cast<void*>(&args)...);
foo(typeid(Args)...);
}
|
google
|
chromium
|
pr33930
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr33930.C
| 169 |
utf_8
|
ed8d33150d8adcb5ff8de3100148a57a
|
// { dg-options "-std=c++0x" }
typedef const int* type;
float& foo( const type& ggg );
int& foo( type&& ggg );
void bar( int* someptr )
{
int& x = foo( someptr );
}
|
google
|
chromium
|
pr39639
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr39639.C
| 457 |
utf_8
|
96e51d00f882d1f43b035d7c6b88a69a
|
// Origin: PR c++/39639
// { dg-options "-std=c++0x" }
// { dg-do "compile" }
template <class... Types>
struct S
: S<...Types>, // { dg-error "expected parameter pack before '...'" }
S<...Types...>, // { dg-error "expected parameter pack before '...'" }
S<...> // { dg-error "expected parameter pack before '...'" }
{
static int f () { return 1;}
};
int
main ()
{
return S<void>::f ();
}
|
google
|
chromium
|
variadic32
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic32.C
| 166 |
utf_8
|
fac9060fdc968ccc2abbb2e4e031e333
|
// { dg-options "-std=gnu++0x" }
template<typename... T>
void eat(const T&...) { }
void f()
{
eat();
eat(1);
eat(1, 2);
eat(17, 3.14159, "Hello, World!");
}
|
google
|
chromium
|
decltype10
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/decltype10.C
| 211 |
utf_8
|
cd06903b180590e9b430016409918b61
|
// PR c++/34271
// { dg-do compile }
// { dg-options "-std=c++0x" }
template<int> struct A
{
static int i;
};
template<int N> int A<N>::i(decltype (A::i; // { dg-error "expected primary-expression before" }
|
google
|
chromium
|
defaulted1
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/defaulted1.C
| 508 |
utf_8
|
dcbdd542e2a8c2332e6116fb05995fba
|
// Positive test for defaulted/deleted fns
// { dg-do run }
// { dg-options "-std=c++0x" }
struct A
{
int i;
A() = default;
A(const A&) = delete;
A& operator=(const A&) = default;
~A();
};
A::~A() = default;
void f() = delete;
struct B
{
int i;
B() = default;
};
int main()
{
A a1, a2;
B b = {1};
a1 = a2;
}
// fns defaulted in class defn are trivial
struct C
{
C() = default;
C(const C&) = default;
C& operator=(const C&) = default;
~C() = default;
};
union U
{
C c;
};
|
google
|
chromium
|
rv8p
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv8p.C
| 1,601 |
utf_8
|
db9c73cee851a3426d9f24047e6126c4
|
// I, Howard Hinnant, hereby place this code in the public domain.
// Test overlaod resolution among referece types
// { dg-do compile }
// { dg-options "-std=c++0x" }
template <bool> struct sa;
template <> struct sa<true> {};
struct one {char x[1];};
struct two {char x[2];};
struct three {char x[3];};
struct four {char x[4];};
struct five {char x[5];};
struct six {char x[6];};
struct seven {char x[7];};
struct eight {char x[8];};
struct A
{
A();
A(const volatile A&&);
};
A source();
const A c_source();
volatile A v_source();
const volatile A cv_source();
// 8 at a time
one sink_8_12345678( A&);
two sink_8_12345678(const A&);
three sink_8_12345678(volatile A&);
four sink_8_12345678(const volatile A&);
five sink_8_12345678( A&&);
six sink_8_12345678(const A&&);
seven sink_8_12345678(volatile A&&);
eight sink_8_12345678(const volatile A&&);
int test8_12345678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_8_12345678(a)) == 1> t1;
sa<sizeof(sink_8_12345678(ca)) == 2> t2;
sa<sizeof(sink_8_12345678(va)) == 3> t3;
sa<sizeof(sink_8_12345678(cva)) == 4> t4;
sa<sizeof(sink_8_12345678(source())) == 5> t5;
sa<sizeof(sink_8_12345678(c_source())) == 6> t6;
sa<sizeof(sink_8_12345678(v_source())) == 7> t7;
sa<sizeof(sink_8_12345678(cv_source())) == 8> t8;
return 0;
}
int main()
{
return test8_12345678();
}
|
google
|
chromium
|
vt-35023
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-35023.C
| 154 |
utf_8
|
2b38f59ec8e6d60420f891e4a59bd87e
|
// { dg-options "-std=c++0x" }
template<typename... T> int foo()
{
T t; // { dg-error "parameter packs|T" }
return t;
}
void bar()
{
foo<int>();
}
|
google
|
chromium
|
inline-ns3
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/inline-ns3.C
| 175 |
utf_8
|
3d2ad7021dde84320aec4eda4fa51879
|
namespace C
{
void f();
}
namespace B
{
using namespace C;
inline namespace B1
{
void f();
}
}
namespace A
{
using namespace B;
}
int main()
{
A::f();
}
|
google
|
chromium
|
variadic49
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic49.C
| 134 |
utf_8
|
abee30ec4450ea9478294337b34444d2
|
// { dg-options "-std=gnu++0x" }
int& f(...);
template<typename... Args>
float& f(Args...);
float& g() {
return f(17, 3.14159);
}
|
google
|
chromium
|
vt-34753
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-34753.C
| 248 |
utf_8
|
eacfe743dafefa8e5b45ff340b870465
|
// { dg-options "-std=c++0x" }
template<typename... T> struct A
{
template<T> struct B {}; // { dg-error "not expanded|T" }
};
A<int>::B<0> b;
template<typename... T> struct B
{
template<T> B(); // { dg-error "not expanded|T" }
};
B<int> c;
|
google
|
chromium
|
vt-35331
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-35331.C
| 159 |
utf_8
|
a3ddb240ea5bf754f530e48afeaf5506
|
// { dg-options "-std=c++0x" }
template<typename...> struct A;
template<typename...T> struct A<T*> // { dg-error "not expanded|T" }
{
friend void foo();
};
|
google
|
chromium
|
rv10
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv10.C
| 152 |
utf_8
|
5cd3e13f4cef7d25383fdec4ba84fae2
|
// { dg-options "-std=gnu++0x" }
struct A
{
A() = default;
A(const A&) = delete;
};
A&& f();
void h(A&&);
void g()
{
A&& arr = f();
h(f());
}
|
google
|
chromium
|
initlist8
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/initlist8.C
| 145 |
utf_8
|
d3a348c4b49e1b0531708a46d1a74cce
|
// PR c++/37740
// { dg-options "-std=c++0x" }
struct A
{
int i;
};
struct B
{
double d;
A i;
};
int main()
{
A a;
new B{3.2, a};
}
|
google
|
chromium
|
vt-35242
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-35242.C
| 162 |
utf_8
|
ffb7b95267980086fce519711a782435
|
// { dg-options "-std=c++0x" }
struct A
{
template<typename... T> struct B;
};
template<typename... T> struct A::B<T*> {}; // { dg-error "parameter packs|T" }
|
google
|
chromium
|
trailing1
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/trailing1.C
| 2,206 |
utf_8
|
90079c108a8e599c1967a81adc4208dd
|
// Tests for late-specified return type.
// { dg-options "-std=c++0x" }
auto f() -> int
{
return 0;
}
template<class T, class U>
auto add(T t, U u) -> decltype (t+u)
{
return t+u;
}
template<class T, class U>
decltype(T()+U()) add2(T t, U u)
{
return t+u;
}
template <class T, class U>
U ag (T, U)
{
return U();
}
template<class T, class U>
auto add3(T t, U u) -> decltype (ag(t,u))
{
return ag(t,u);
}
template<class T, class U>
decltype(*(T*)0+*(U*)0) add4(T t, U u)
{
return t+u;
}
template <class T>
struct A
{
T f() {}
template <class U>
T g() {}
template <class V>
struct B
{
int MEM;
};
};
template <class T>
auto f(T* t) -> decltype (t->f())
{
return t->f();
}
template <class T>
auto g(T t) -> decltype (t.f())
{
return t.f();
}
template <class T, class U>
auto h(T t, U u) -> decltype (t.template g<U>())
{
return t.template g<U>();
}
struct D { };
struct C: public A<int>::B<D>
{
};
template <class T, class U, class V>
auto k(T t, U u, V v) -> decltype (t.U::template B<V>::MEM)
{
return t.U::template B<V>::MEM;
}
// For these two examples we can elide the 'decltype' and just mangle the type.
template <class T>
auto l(T t) -> decltype (t)
{
return t;
}
template <class T, T u>
auto m(T t) -> decltype (u)
{
return t;
}
A<int> a, *p;
int main()
{
// { dg-final { scan-assembler "_Z3addIidEDTplfp_fp0_ET_T0_" } }
auto i = add(1, 2.0);
// { dg-final { scan-assembler "_Z4add4IidEDTpldecvPT_Li0EdecvPT0_Li0EES0_S2_" } }
auto i4 = add4(1, 2.0);
// { dg-final { scan-assembler "_Z4add2IidEDTplcvT__EcvT0__EES0_S1_" } }
auto i2 = add2(1, 2.0);
// { dg-final { scan-assembler "_Z4add3IidEDTcl2agfp_fp0_EET_T0_" } }
auto i3 = add3(1, 2.0);
// { dg-final { scan-assembler "_Z1fI1AIiEEDTclptfp_1fEEPT_" } }
f(p);
// { dg-final { scan-assembler "_Z1gI1AIiEEDTcldtfp_1fEET_" } }
g(a);
// { dg-final { scan-assembler "_Z1hI1AIiEdEDTcldtfp_1gIT0_EEET_S2_" } }
h(a,1.0);
// { dg-final { scan-assembler "_Z1kI1C1AIiE1DEDtdtfp_srNT0_1BIT1_EE3MEMET_S4_S6_" } }
k( C(), A<int>(), D() );
// { dg-final { scan-assembler "_Z1lIiET_S0_" } }
l(1);
// { dg-final { scan-assembler "_Z1mIiLi1EET_S0_" } }
m<int,1>(1);
}
|
google
|
chromium
|
vt-34055
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-34055.C
| 672 |
utf_8
|
c2357ee79aa07dbc9e108c0c7ad46133
|
// { dg-options "-std=c++0x" }
// PR c++/34055
template<typename...> struct A;
template<typename...T> struct A<T*> // { dg-error "parameter packs|T" }
{
void foo();
};
template<typename...T> void A<T*>::foo() {} // { dg-error "invalid declarator" }
template<typename...> struct B;
template<typename...T> struct B<T&> // { dg-error "parameter packs|T" }
{
void foo();
};
template<typename...T> void B<T&>::foo() {} // { dg-error "invalid declarator" }
template<typename...> struct C;
template<typename...T> struct C<T()> // { dg-error "parameter packs|T" }
{
void foo();
};
template<typename...T> void C<T()>::foo() {} // { dg-error "invalid declarator" }
|
google
|
chromium
|
vt-34755
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-34755.C
| 221 |
utf_8
|
0f764787d40ed4f9f7ad1a7c54e7bc2b
|
// { dg-options "-std=c++0x" }
template<typename> struct A {};
template<template<typename> class... T> void foo(T<int>) {} // { dg-error "not expanded|T" }
template void foo<A>(A<int>); // { dg-error "does not match" }
|
google
|
chromium
|
auto15
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/auto15.C
| 241 |
utf_8
|
e3505db416fb041ea0d0db503cc713f1
|
// { dg-options "-std=c++0x" }
template< typename Fn > struct function;
template< typename Result, typename ... ArgTypes >
struct function< auto (ArgTypes...)->Result > {
};
int main()
{
function< auto(double)->int > y;
return 0;
}
|
google
|
chromium
|
rv4n
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv4n.C
| 23,942 |
utf_8
|
0a9fa2b71927c4fbeab0d8e5a0984da7
|
// I, Howard Hinnant, hereby place this code in the public domain.
// Test overlaod resolution among referece types
// { dg-do compile }
// { dg-options "-std=c++0x" }
template <bool> struct sa;
template <> struct sa<true> {};
struct one {char x[1];};
struct two {char x[2];};
struct three {char x[3];};
struct four {char x[4];};
struct five {char x[5];};
struct six {char x[6];};
struct seven {char x[7];};
struct eight {char x[8];};
struct A
{
A();
A(const volatile A&&);
};
A source();
const A c_source();
volatile A v_source();
const volatile A cv_source();
// 4 at a time
one sink_4_1234( A&); // { dg-message "candidates" }
two sink_4_1234(const A&); // { dg-message "note" }
three sink_4_1234(volatile A&); // { dg-message "note" }
four sink_4_1234(const volatile A&); // { dg-message "note" }
int test4_1234()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1234(v_source()); // { dg-error "no match" }
sink_4_1234(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1235( A&); // { dg-message "candidates" }
two sink_4_1235(const A&); // { dg-message "note" }
three sink_4_1235(volatile A&); // { dg-message "note" }
five sink_4_1235( A&&); // { dg-message "note" }
int test4_1235()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1235(cva); // { dg-error "no match" }
sink_4_1235(v_source()); // { dg-error "no match" }
sink_4_1235(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1236( A&); // { dg-message "candidates" }
two sink_4_1236(const A&); // { dg-message "note" }
three sink_4_1236(volatile A&); // { dg-message "note" }
six sink_4_1236(const A&&); // { dg-message "note" }
int test4_1236()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1236(cva); // { dg-error "no match" }
sink_4_1236(v_source()); // { dg-error "no match" }
sink_4_1236(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1237( A&); // { dg-message "candidates" }
two sink_4_1237(const A&); // { dg-message "note" }
three sink_4_1237(volatile A&); // { dg-message "note" }
seven sink_4_1237(volatile A&&); // { dg-message "note" }
int test4_1237()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1237(cva); // { dg-error "no match" }
sink_4_1237(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1245( A&); // { dg-message "candidates" }
two sink_4_1245(const A&); // { dg-message "note" }
four sink_4_1245(const volatile A&); // { dg-message "note" }
five sink_4_1245( A&&); // { dg-message "note" }
int test4_1245()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1245(v_source()); // { dg-error "no match" }
sink_4_1245(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1246( A&); // { dg-message "candidates" }
two sink_4_1246(const A&); // { dg-message "note" }
four sink_4_1246(const volatile A&); // { dg-message "note" }
six sink_4_1246(const A&&); // { dg-message "note" }
int test4_1246()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1246(v_source()); // { dg-error "no match" }
sink_4_1246(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1247( A&); // { dg-message "candidates" }
two sink_4_1247(const A&); // { dg-message "note" }
four sink_4_1247(const volatile A&); // { dg-message "note" }
seven sink_4_1247(volatile A&&); // { dg-message "note" }
int test4_1247()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1247(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1256( A&); // { dg-message "candidates" }
two sink_4_1256(const A&); // { dg-message "note" }
five sink_4_1256( A&&); // { dg-message "note" }
six sink_4_1256(const A&&); // { dg-message "note" }
int test4_1256()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1256(va); // { dg-error "no match" }
sink_4_1256(cva); // { dg-error "no match" }
sink_4_1256(v_source()); // { dg-error "no match" }
sink_4_1256(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1257( A&); // { dg-message "candidates" }
two sink_4_1257(const A&); // { dg-message "note" }
five sink_4_1257( A&&); // { dg-message "note" }
seven sink_4_1257(volatile A&&); // { dg-message "note" }
int test4_1257()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1257(cva); // { dg-error "no match" }
sink_4_1257(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1267( A&); // { dg-message "candidates" }
two sink_4_1267(const A&); // { dg-message "note" }
six sink_4_1267(const A&&); // { dg-message "note" }
seven sink_4_1267(volatile A&&); // { dg-message "note" }
int test4_1267()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1267(cva); // { dg-error "no match" }
sink_4_1267(source()); // { dg-error "ambiguous" }
sink_4_1267(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1345( A&); // { dg-message "candidates" }
three sink_4_1345(volatile A&); // { dg-message "note" }
four sink_4_1345(const volatile A&); // { dg-message "note" }
five sink_4_1345( A&&); // { dg-message "note" }
int test4_1345()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1345(c_source()); // { dg-error "no match" }
sink_4_1345(v_source()); // { dg-error "no match" }
sink_4_1345(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1346( A&); // { dg-message "candidates" }
three sink_4_1346(volatile A&); // { dg-message "note" }
four sink_4_1346(const volatile A&); // { dg-message "note" }
six sink_4_1346(const A&&); // { dg-message "note" }
int test4_1346()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1346(v_source()); // { dg-error "no match" }
sink_4_1346(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1347( A&); // { dg-message "candidates" }
three sink_4_1347(volatile A&); // { dg-message "note" }
four sink_4_1347(const volatile A&); // { dg-message "note" }
seven sink_4_1347(volatile A&&); // { dg-message "note" }
int test4_1347()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1347(c_source()); // { dg-error "no match" }
sink_4_1347(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1356( A&); // { dg-message "candidates" }
three sink_4_1356(volatile A&); // { dg-message "note" }
five sink_4_1356( A&&); // { dg-message "note" }
six sink_4_1356(const A&&); // { dg-message "note" }
int test4_1356()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1356(cva); // { dg-error "no match" }
sink_4_1356(v_source()); // { dg-error "no match" }
sink_4_1356(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1357( A&); // { dg-message "candidates" }
three sink_4_1357(volatile A&); // { dg-message "note" }
five sink_4_1357( A&&); // { dg-message "note" }
seven sink_4_1357(volatile A&&); // { dg-message "note" }
int test4_1357()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1357(ca); // { dg-error "no match" }
sink_4_1357(cva); // { dg-error "no match" }
sink_4_1357(c_source()); // { dg-error "no match" }
sink_4_1357(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1367( A&); // { dg-message "candidates" }
three sink_4_1367(volatile A&); // { dg-message "note" }
six sink_4_1367(const A&&); // { dg-message "note" }
seven sink_4_1367(volatile A&&); // { dg-message "note" }
int test4_1367()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1367(cva); // { dg-error "no match" }
sink_4_1367(source()); // { dg-error "ambiguous" }
sink_4_1367(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1456( A&); // { dg-message "candidates" }
four sink_4_1456(const volatile A&); // { dg-message "note" }
five sink_4_1456( A&&); // { dg-message "note" }
six sink_4_1456(const A&&); // { dg-message "note" }
int test4_1456()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1456(v_source()); // { dg-error "no match" }
sink_4_1456(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1457( A&); // { dg-message "candidates" }
four sink_4_1457(const volatile A&); // { dg-message "note" }
five sink_4_1457( A&&); // { dg-message "note" }
seven sink_4_1457(volatile A&&); // { dg-message "note" }
int test4_1457()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1457(c_source()); // { dg-error "no match" }
sink_4_1457(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1467( A&); // { dg-message "candidates" }
four sink_4_1467(const volatile A&); // { dg-message "note" }
six sink_4_1467(const A&&); // { dg-message "note" }
seven sink_4_1467(volatile A&&); // { dg-message "note" }
int test4_1467()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1467(source()); // { dg-error "ambiguous" }
sink_4_1467(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1567( A&); // { dg-message "candidates" }
five sink_4_1567( A&&); // { dg-message "note" }
six sink_4_1567(const A&&); // { dg-message "note" }
seven sink_4_1567(volatile A&&); // { dg-message "note" }
int test4_1567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1567(cva); // { dg-error "no match" }
sink_4_1567(cv_source()); // { dg-error "no match" }
return 0;
}
one sink_4_1678( A&);
six sink_4_1678(const A&&); // { dg-message "candidates" }
seven sink_4_1678(volatile A&&); // { dg-message "note" }
eight sink_4_1678(const volatile A&&); // { dg-message "note" }
int test4_1678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_1678(source()); // { dg-error "ambiguous" }
return 0;
}
two sink_4_2345(const A&); // { dg-message "candidates" }
three sink_4_2345(volatile A&); // { dg-message "note" }
four sink_4_2345(const volatile A&); // { dg-message "note" }
five sink_4_2345( A&&); // { dg-message "note" }
int test4_2345()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2345(a); // { dg-error "ambiguous" }
sink_4_2345(v_source()); // { dg-error "no match" }
sink_4_2345(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2346(const A&); // { dg-message "candidates" }
three sink_4_2346(volatile A&); // { dg-message "note" }
four sink_4_2346(const volatile A&); // { dg-message "note" }
six sink_4_2346(const A&&); // { dg-message "note" }
int test4_2346()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2346(a); // { dg-error "ambiguous" }
sink_4_2346(v_source()); // { dg-error "no match" }
sink_4_2346(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2347(const A&); // { dg-message "candidates" }
three sink_4_2347(volatile A&); // { dg-message "note" }
four sink_4_2347(const volatile A&); // { dg-message "note" }
seven sink_4_2347(volatile A&&); // { dg-message "note" }
int test4_2347()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2347(a); // { dg-error "ambiguous" }
sink_4_2347(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2348(const A&); // { dg-message "candidates" }
three sink_4_2348(volatile A&); // { dg-message "note" }
four sink_4_2348(const volatile A&); // { dg-message "note" }
eight sink_4_2348(const volatile A&&); // { dg-message "note" }
int test4_2348()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2348(a); // { dg-error "ambiguous" }
return 0;
}
two sink_4_2356(const A&); // { dg-message "candidates" }
three sink_4_2356(volatile A&); // { dg-message "note" }
five sink_4_2356( A&&); // { dg-message "note" }
six sink_4_2356(const A&&); // { dg-message "note" }
int test4_2356()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2356(a); // { dg-error "ambiguous" }
sink_4_2356(cva); // { dg-error "no match" }
sink_4_2356(v_source()); // { dg-error "no match" }
sink_4_2356(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2357(const A&); // { dg-message "candidates" }
three sink_4_2357(volatile A&); // { dg-message "note" }
five sink_4_2357( A&&); // { dg-message "note" }
seven sink_4_2357(volatile A&&); // { dg-message "note" }
int test4_2357()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2357(a); // { dg-error "ambiguous" }
sink_4_2357(cva); // { dg-error "no match" }
sink_4_2357(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2358(const A&); // { dg-message "candidates" }
three sink_4_2358(volatile A&); // { dg-message "note" }
five sink_4_2358( A&&); // { dg-message "note" }
eight sink_4_2358(const volatile A&&); // { dg-message "note" }
int test4_2358()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2358(a); // { dg-error "ambiguous" }
return 0;
}
two sink_4_2367(const A&); // { dg-message "candidates" }
three sink_4_2367(volatile A&); // { dg-message "note" }
six sink_4_2367(const A&&); // { dg-message "note" }
seven sink_4_2367(volatile A&&); // { dg-message "note" }
int test4_2367()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2367(a); // { dg-error "ambiguous" }
sink_4_2367(cva); // { dg-error "no match" }
sink_4_2367(source()); // { dg-error "ambiguous" }
sink_4_2367(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2368(const A&); // { dg-message "candidates" }
three sink_4_2368(volatile A&); // { dg-message "note" }
six sink_4_2368(const A&&); // { dg-message "note" }
eight sink_4_2368(const volatile A&&); // { dg-message "note" }
int test4_2368()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2368(a); // { dg-error "ambiguous" }
return 0;
}
two sink_4_2378(const A&); // { dg-message "candidates" }
three sink_4_2378(volatile A&); // { dg-message "note" }
seven sink_4_2378(volatile A&&); // { dg-message "note" }
eight sink_4_2378(const volatile A&&); // { dg-message "note" }
int test4_2378()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2378(a); // { dg-error "ambiguous" }
return 0;
}
two sink_4_2456(const A&); // { dg-message "candidates" }
four sink_4_2456(const volatile A&); // { dg-message "note" }
five sink_4_2456( A&&); // { dg-message "note" }
six sink_4_2456(const A&&); // { dg-message "note" }
int test4_2456()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2456(v_source()); // { dg-error "no match" }
sink_4_2456(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2457(const A&); // { dg-message "candidates" }
four sink_4_2457(const volatile A&); // { dg-message "note" }
five sink_4_2457( A&&); // { dg-message "note" }
seven sink_4_2457(volatile A&&); // { dg-message "note" }
int test4_2457()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2457(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2467(const A&); // { dg-message "candidates" }
four sink_4_2467(const volatile A&); // { dg-message "note" }
six sink_4_2467(const A&&); // { dg-message "note" }
seven sink_4_2467(volatile A&&); // { dg-message "note" }
int test4_2467()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2467(source()); // { dg-error "ambiguous" }
sink_4_2467(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2567(const A&); // { dg-message "candidates" }
five sink_4_2567( A&&); // { dg-message "note" }
six sink_4_2567(const A&&); // { dg-message "note" }
seven sink_4_2567(volatile A&&); // { dg-message "note" }
int test4_2567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2567(cva); // { dg-error "no match" }
sink_4_2567(cv_source()); // { dg-error "no match" }
return 0;
}
two sink_4_2678(const A&); // { dg-message "candidates" }
six sink_4_2678(const A&&); // { dg-message "note" }
seven sink_4_2678(volatile A&&); // { dg-message "note" }
eight sink_4_2678(const volatile A&&); // { dg-message "note" }
int test4_2678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_2678(source()); // { dg-error "ambiguous" }
return 0;
}
three sink_4_3456(volatile A&); // { dg-message "candidates" }
four sink_4_3456(const volatile A&); // { dg-message "note" }
five sink_4_3456( A&&); // { dg-message "note" }
six sink_4_3456(const A&&); // { dg-message "note" }
int test4_3456()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_3456(v_source()); // { dg-error "no match" }
sink_4_3456(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_4_3457(volatile A&); // { dg-message "candidates" }
four sink_4_3457(const volatile A&); // { dg-message "note" }
five sink_4_3457( A&&); // { dg-message "note" }
seven sink_4_3457(volatile A&&); // { dg-message "note" }
int test4_3457()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_3457(c_source()); // { dg-error "no match" }
sink_4_3457(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_4_3467(volatile A&); // { dg-message "candidates" }
four sink_4_3467(const volatile A&); // { dg-message "note" }
six sink_4_3467(const A&&); // { dg-message "note" }
seven sink_4_3467(volatile A&&); // { dg-message "note" }
int test4_3467()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_3467(source()); // { dg-error "ambiguous" }
sink_4_3467(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_4_3567(volatile A&); // { dg-message "candidates" }
five sink_4_3567( A&&); // { dg-message "note" }
six sink_4_3567(const A&&); // { dg-message "note" }
seven sink_4_3567(volatile A&&); // { dg-message "note" }
int test4_3567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_3567(cva); // { dg-error "no match" }
sink_4_3567(cv_source()); // { dg-error "no match" }
return 0;
}
three sink_4_3678(volatile A&);
six sink_4_3678(const A&&); // { dg-message "candidates" }
seven sink_4_3678(volatile A&&); // { dg-message "note" }
eight sink_4_3678(const volatile A&&); // { dg-message "note" }
int test4_3678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_3678(source()); // { dg-error "ambiguous" }
return 0;
}
four sink_4_4567(const volatile A&); // { dg-message "candidates" }
five sink_4_4567( A&&); // { dg-message "note" }
six sink_4_4567(const A&&); // { dg-message "note" }
seven sink_4_4567(volatile A&&); // { dg-message "note" }
int test4_4567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_4567(cv_source()); // { dg-error "no match" }
return 0;
}
four sink_4_4678(const volatile A&);
six sink_4_4678(const A&&); // { dg-message "candidates" }
seven sink_4_4678(volatile A&&); // { dg-message "note" }
eight sink_4_4678(const volatile A&&); // { dg-message "note" }
int test4_4678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sink_4_4678(source()); // { dg-error "ambiguous" }
return 0;
}
int main()
{
return test4_1235() + test4_1236() + test4_1237() + test4_1256() + test4_1257() +
test4_1267() + test4_1356() + test4_1357() + test4_1467() + test4_1567() +
test4_1678() + test4_2345() + test4_2346() + test4_2347() + test4_2348() +
test4_2356() + test4_2357() + test4_2358() + test4_2367() + test4_2368() +
test4_2378() + test4_2467() + test4_2567() + test4_2678() + test4_3467() +
test4_3567() + test4_3678() + test4_4678();
}
|
google
|
chromium
|
variadic61
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic61.C
| 122 |
utf_8
|
fc2fc2c87d783c7e4469a5ddeec5b902
|
// { dg-options "-std=gnu++98 -pedantic" }
template<typename... Args> class tuple; // { dg-warning "variadic templates" }
|
google
|
chromium
|
variadic45
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic45.C
| 174 |
utf_8
|
cb52c389d45c5f0d316d702504602e56
|
// { dg-options "-std=gnu++0x" }
template<typename... Args>
int& f(Args...);
template<typename T1, typename T2>
float& f(T1, T2);
float& g() {
return f(17, 3.14159);
}
|
google
|
chromium
|
variadic92
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic92.C
| 1,357 |
utf_8
|
52ab8919bc0cd7496f7516a7181f8a64
|
// Various tests for variadic templates and partial specialization.
// { dg-options "-std=c++0x" }
// PR c++/36846
template<typename A, typename B>
struct pair;
template<typename... T>
struct pairs;
template<typename... AS, typename... BS>
struct pairs<pair<AS, BS>...> {
struct mismatched_packs {};
};
template class pairs<
pair<int, int>,
pair<int, int>
>;
template<int A, int B>
struct point;
template<typename... T>
struct points;
template<int... AS, int... BS>
struct points<point<AS, BS>...> {
struct mismatched_packs {};
};
template class points<
point<0, 1>,
point<0, 1>
>;
// PR c++/35477
template <class...ARGS> struct tuple {};
template <class A, class B> struct test {};
template <class... ARGS, class B> struct test<B, tuple<ARGS...>>
{
template <class T> struct inside {};
};
// PR c++/38276
template<typename...> struct A;
template<typename, typename> struct B;
template<typename... T, typename... U> struct B<A<T...>, A<U...> >
{
static int i;
};
B<A<>, A<int> > b1;
B<A<int>, A<> > b2;
// PR c++/35784
template <typename...> struct p;
template <typename, typename> struct d;
template <typename... A, typename... B>
struct d<p<A...>, p<B...> > { typedef int t; };
typedef d<p<>, p<int, float> >::t q;
typedef d<q, d<p<int>, p<float> >::t> r; // *
typedef d<d<p<>, p<int, float> >::t, d<p<>, p<> >::t> s;
|
google
|
chromium
|
variadic37
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic37.C
| 265 |
utf_8
|
07ad629a9fe7358117b28c60d1d1916e
|
// { dg-options "-std=gnu++0x" }
template<typename... Values>
struct tuple
{
static const __SIZE_TYPE__ length = sizeof...(Values);
};
int a0[tuple<>::length == 0? 1 : -1];
int a1[tuple<int>::length == 1? 1 : -1];
int a2[tuple<int, float>::length == 2? 1 : -1];
|
google
|
chromium
|
rv2p
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv2p.C
| 14,749 |
utf_8
|
2c4bd4b466f8ccc772160cc823ec1a40
|
// I, Howard Hinnant, hereby place this code in the public domain.
// Test overlaod resolution among referece types
// { dg-do compile }
// { dg-options "-std=c++0x" }
template <bool> struct sa;
template <> struct sa<true> {};
struct one {char x[1];};
struct two {char x[2];};
struct three {char x[3];};
struct four {char x[4];};
struct five {char x[5];};
struct six {char x[6];};
struct seven {char x[7];};
struct eight {char x[8];};
struct A
{
A();
A(const volatile A&&);
};
A source();
const A c_source();
volatile A v_source();
const volatile A cv_source();
// 2 at a time
one sink_2_12( A&);
two sink_2_12(const A&);
int test2_12()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_12(a)) == 1> t1;
sa<sizeof(sink_2_12(ca)) == 2> t2;
sa<sizeof(sink_2_12(source())) == 2> t5;
sa<sizeof(sink_2_12(c_source())) == 2> t6;
return 0;
}
one sink_2_13( A&);
three sink_2_13(volatile A&);
int test2_13()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_13(a)) == 1> t1;
sa<sizeof(sink_2_13(va)) == 3> t3;
return 0;
}
one sink_2_14( A&);
four sink_2_14(const volatile A&);
int test2_14()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_14(a)) == 1> t1;
sa<sizeof(sink_2_14(ca)) == 4> t2;
sa<sizeof(sink_2_14(va)) == 4> t3;
sa<sizeof(sink_2_14(cva)) == 4> t4;
return 0;
}
one sink_2_15( A&);
five sink_2_15( A&&);
int test2_15()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_15(a)) == 1> t1;
sa<sizeof(sink_2_15(source())) == 5> t5;
return 0;
}
one sink_2_16( A&);
six sink_2_16(const A&&);
int test2_16()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_16(a)) == 1> t1;
sa<sizeof(sink_2_16(ca)) == 6> t2;
sa<sizeof(sink_2_16(source())) == 6> t5;
sa<sizeof(sink_2_16(c_source())) == 6> t6;
return 0;
}
one sink_2_17( A&);
seven sink_2_17(volatile A&&);
int test2_17()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_17(a)) == 1> t1;
sa<sizeof(sink_2_17(va)) == 7> t3;
sa<sizeof(sink_2_17(source())) == 7> t5;
sa<sizeof(sink_2_17(v_source())) == 7> t7;
return 0;
}
one sink_2_18( A&);
eight sink_2_18(const volatile A&&);
int test2_18()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_18(a)) == 1> t1;
sa<sizeof(sink_2_18(ca)) == 8> t2;
sa<sizeof(sink_2_18(va)) == 8> t3;
sa<sizeof(sink_2_18(cva)) == 8> t4;
sa<sizeof(sink_2_18(source())) == 8> t5;
sa<sizeof(sink_2_18(c_source())) == 8> t6;
sa<sizeof(sink_2_18(v_source())) == 8> t7;
sa<sizeof(sink_2_18(cv_source())) == 8> t8;
return 0;
}
two sink_2_23(const A&);
three sink_2_23(volatile A&);
int test2_23()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_23(ca)) == 2> t2;
sa<sizeof(sink_2_23(va)) == 3> t3;
sa<sizeof(sink_2_23(source())) == 2> t5;
sa<sizeof(sink_2_23(c_source())) == 2> t6;
return 0;
}
two sink_2_24(const A&);
four sink_2_24(const volatile A&);
int test2_24()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_24(a)) == 2> t1;
sa<sizeof(sink_2_24(ca)) == 2> t2;
sa<sizeof(sink_2_24(va)) == 4> t3;
sa<sizeof(sink_2_24(cva)) == 4> t4;
sa<sizeof(sink_2_24(source())) == 2> t5;
sa<sizeof(sink_2_24(c_source())) == 2> t6;
// sa<sizeof(sink_2_24(v_source())) == 4> t7;
// sa<sizeof(sink_2_24(cv_source())) == 4> t8;
return 0;
}
two sink_2_25(const A&);
five sink_2_25( A&&);
int test2_25()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_25(a)) == 2> t1;
sa<sizeof(sink_2_25(ca)) == 2> t2;
sa<sizeof(sink_2_25(source())) == 5> t5;
sa<sizeof(sink_2_25(c_source())) == 2> t6;
return 0;
}
two sink_2_26(const A&);
six sink_2_26(const A&&);
int test2_26()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_26(a)) == 2> t1;
sa<sizeof(sink_2_26(ca)) == 2> t2;
sa<sizeof(sink_2_26(source())) == 6> t5;
sa<sizeof(sink_2_26(c_source())) == 6> t6;
return 0;
}
two sink_2_27(const A&);
seven sink_2_27(volatile A&&);
int test2_27()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_27(a)) == 2> t1;
sa<sizeof(sink_2_27(ca)) == 2> t2;
sa<sizeof(sink_2_27(va)) == 7> t3;
sa<sizeof(sink_2_27(source())) == 7> t5;
sa<sizeof(sink_2_27(c_source())) == 2> t6;
sa<sizeof(sink_2_27(v_source())) == 7> t7;
return 0;
}
two sink_2_28(const A&);
eight sink_2_28(const volatile A&&);
int test2_28()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_28(a)) == 2> t1;
sa<sizeof(sink_2_28(ca)) == 2> t2;
sa<sizeof(sink_2_28(va)) == 8> t3;
sa<sizeof(sink_2_28(cva)) == 8> t4;
sa<sizeof(sink_2_28(source())) == 8> t5;
sa<sizeof(sink_2_28(c_source())) == 8> t6;
sa<sizeof(sink_2_28(v_source())) == 8> t7;
sa<sizeof(sink_2_28(cv_source())) == 8> t8;
return 0;
}
three sink_2_34(volatile A&);
four sink_2_34(const volatile A&);
int test2_34()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_34(a)) == 3> t1;
sa<sizeof(sink_2_34(ca)) == 4> t2;
sa<sizeof(sink_2_34(va)) == 3> t3;
sa<sizeof(sink_2_34(cva)) == 4> t4;
// sa<sizeof(sink_2_34(source())) == 4> t5;
// sa<sizeof(sink_2_34(c_source())) == 4> t6;
// sa<sizeof(sink_2_34(v_source())) == 4> t7;
// sa<sizeof(sink_2_34(cv_source())) == 4> t8;
return 0;
}
three sink_2_35(volatile A&);
five sink_2_35( A&&);
int test2_35()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_35(a)) == 3> t1;
sa<sizeof(sink_2_35(va)) == 3> t3;
sa<sizeof(sink_2_35(source())) == 5> t5;
return 0;
}
three sink_2_36(volatile A&);
six sink_2_36(const A&&);
int test2_36()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_36(a)) == 3> t1;
sa<sizeof(sink_2_36(ca)) == 6> t2;
sa<sizeof(sink_2_36(va)) == 3> t3;
sa<sizeof(sink_2_36(source())) == 6> t5;
sa<sizeof(sink_2_36(c_source())) == 6> t6;
return 0;
}
three sink_2_37(volatile A&);
seven sink_2_37(volatile A&&);
int test2_37()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_37(a)) == 3> t1;
sa<sizeof(sink_2_37(va)) == 3> t3;
sa<sizeof(sink_2_37(source())) == 7> t5;
sa<sizeof(sink_2_37(v_source())) == 7> t7;
return 0;
}
three sink_2_38(volatile A&);
eight sink_2_38(const volatile A&&);
int test2_38()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_38(a)) == 3> t1;
sa<sizeof(sink_2_38(ca)) == 8> t2;
sa<sizeof(sink_2_38(va)) == 3> t3;
sa<sizeof(sink_2_38(cva)) == 8> t4;
sa<sizeof(sink_2_38(source())) == 8> t5;
sa<sizeof(sink_2_38(c_source())) == 8> t6;
sa<sizeof(sink_2_38(v_source())) == 8> t7;
sa<sizeof(sink_2_38(cv_source())) == 8> t8;
return 0;
}
four sink_2_45(const volatile A&);
five sink_2_45( A&&);
int test2_45()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_45(a)) == 4> t1;
sa<sizeof(sink_2_45(ca)) == 4> t2;
sa<sizeof(sink_2_45(va)) == 4> t3;
sa<sizeof(sink_2_45(cva)) == 4> t4;
sa<sizeof(sink_2_45(source())) == 5> t5;
// sa<sizeof(sink_2_45(c_source())) == 4> t6;
// sa<sizeof(sink_2_45(v_source())) == 4> t7;
// sa<sizeof(sink_2_45(cv_source())) == 4> t8;
return 0;
}
four sink_2_46(const volatile A&);
six sink_2_46(const A&&);
int test2_46()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_46(a)) == 4> t1;
sa<sizeof(sink_2_46(ca)) == 4> t2;
sa<sizeof(sink_2_46(va)) == 4> t3;
sa<sizeof(sink_2_46(cva)) == 4> t4;
sa<sizeof(sink_2_46(source())) == 6> t5;
sa<sizeof(sink_2_46(c_source())) == 6> t6;
// sa<sizeof(sink_2_46(v_source())) == 4> t7;
// sa<sizeof(sink_2_46(cv_source())) == 4> t8;
return 0;
}
four sink_2_47(const volatile A&);
seven sink_2_47(volatile A&&);
int test2_47()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_47(a)) == 4> t1;
sa<sizeof(sink_2_47(ca)) == 4> t2;
sa<sizeof(sink_2_47(va)) == 4> t3;
sa<sizeof(sink_2_47(cva)) == 4> t4;
sa<sizeof(sink_2_47(source())) == 7> t5;
// sa<sizeof(sink_2_47(c_source())) == 4> t6;
sa<sizeof(sink_2_47(v_source())) == 7> t7;
// sa<sizeof(sink_2_47(cv_source())) == 4> t8;
return 0;
}
four sink_2_48(const volatile A&);
eight sink_2_48(const volatile A&&);
int test2_48()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_48(a)) == 4> t1;
sa<sizeof(sink_2_48(ca)) == 4> t2;
sa<sizeof(sink_2_48(va)) == 4> t3;
sa<sizeof(sink_2_48(cva)) == 4> t4;
sa<sizeof(sink_2_48(source())) == 8> t5;
sa<sizeof(sink_2_48(c_source())) == 8> t6;
sa<sizeof(sink_2_48(v_source())) == 8> t7;
sa<sizeof(sink_2_48(cv_source())) == 8> t8;
return 0;
}
five sink_2_56( A&&);
six sink_2_56(const A&&);
int test2_56()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_56(a)) == 5> t1;
sa<sizeof(sink_2_56(ca)) == 6> t2;
sa<sizeof(sink_2_56(source())) == 5> t5;
sa<sizeof(sink_2_56(c_source())) == 6> t6;
return 0;
}
five sink_2_57( A&&);
seven sink_2_57(volatile A&&);
int test2_57()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_57(a)) == 5> t1;
sa<sizeof(sink_2_57(va)) == 7> t3;
sa<sizeof(sink_2_57(source())) == 5> t5;
sa<sizeof(sink_2_57(v_source())) == 7> t7;
return 0;
}
five sink_2_58( A&&);
eight sink_2_58(const volatile A&&);
int test2_58()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_58(a)) == 5> t1;
sa<sizeof(sink_2_58(ca)) == 8> t2;
sa<sizeof(sink_2_58(va)) == 8> t3;
sa<sizeof(sink_2_58(cva)) == 8> t4;
sa<sizeof(sink_2_58(source())) == 5> t5;
sa<sizeof(sink_2_58(c_source())) == 8> t6;
sa<sizeof(sink_2_58(v_source())) == 8> t7;
sa<sizeof(sink_2_58(cv_source())) == 8> t8;
return 0;
}
six sink_2_67(const A&&);
seven sink_2_67(volatile A&&);
int test2_67()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_67(ca)) == 6> t2;
sa<sizeof(sink_2_67(va)) == 7> t3;
sa<sizeof(sink_2_67(c_source())) == 6> t6;
sa<sizeof(sink_2_67(v_source())) == 7> t7;
return 0;
}
six sink_2_68(const A&&);
eight sink_2_68(const volatile A&&);
int test2_68()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_68(a)) == 6> t1;
sa<sizeof(sink_2_68(ca)) == 6> t2;
sa<sizeof(sink_2_68(va)) == 8> t3;
sa<sizeof(sink_2_68(cva)) == 8> t4;
sa<sizeof(sink_2_68(source())) == 6> t5;
sa<sizeof(sink_2_68(c_source())) == 6> t6;
sa<sizeof(sink_2_68(v_source())) == 8> t7;
sa<sizeof(sink_2_68(cv_source())) == 8> t8;
return 0;
}
seven sink_2_78(volatile A&&);
eight sink_2_78(const volatile A&&);
int test2_78()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_2_78(a)) == 7> t1;
sa<sizeof(sink_2_78(ca)) == 8> t2;
sa<sizeof(sink_2_78(va)) == 7> t3;
sa<sizeof(sink_2_78(cva)) == 8> t4;
sa<sizeof(sink_2_78(source())) == 7> t5;
sa<sizeof(sink_2_78(c_source())) == 8> t6;
sa<sizeof(sink_2_78(v_source())) == 7> t7;
sa<sizeof(sink_2_78(cv_source())) == 8> t8;
return 0;
}
int main()
{
return test2_12() + test2_13() + test2_14() + test2_15() +
test2_16() + test2_17() + test2_18() + test2_23() +
test2_24() + test2_25() + test2_26() + test2_27() +
test2_28() + test2_34() + test2_35() + test2_36() +
test2_37() + test2_38() + test2_45() + test2_46() +
test2_47() + test2_48() + test2_56() + test2_57() +
test2_58() + test2_67() + test2_68() + test2_78();
}
|
google
|
chromium
|
vt-34103
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-34103.C
| 245 |
utf_8
|
4ce2ee23d4adb071c7bf282eebc82eb3
|
// { dg-options "-std=c++0x" }
// PR c++/34103
template<typename> struct A {};
template<typename...T> void foo(A<T>, A<T>); // { dg-error "parameter packs|T" }
template<typename...T> void foo(A<T>, A<T>) {} // { dg-error "parameter packs|T" }
|
google
|
chromium
|
variadic66
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic66.C
| 177 |
utf_8
|
c3f06cf86e54c908fb0645bdc2f64ad6
|
// { dg-options "-std=gnu++0x" }
template<typename Result, typename Functor, typename... ArgTypes>
Result bind(Functor, ArgTypes...) { }
void f()
{
bind<int>(17, 20, 22);
}
|
google
|
chromium
|
vt-35024
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-35024.C
| 166 |
utf_8
|
6de03c7edd71c45e3ff9011def618a5d
|
// { dg-options "-std=c++0x" }
template<typename... T> int foo()
{
typename T::X x; // { dg-error "parameter packs|T" }
return x;
}
void bar()
{
foo<int>();
}
|
google
|
chromium
|
defaulted4
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/defaulted4.C
| 460 |
utf_8
|
c163e76b6fe04152df8ad492d1575982
|
// PR c++/37208: SFINAE and deleted functions.
// { dg-options "-std=c++0x" }
// { dg-do compile }
template<int> struct A { };
template<typename T>
int& int_if_addable(A<sizeof((*(T*)0) + (*(T*)0))>*);
template<typename T>
float& int_if_addable(...);
struct X { };
struct Y { };
Y operator+(Y, Y);
struct Z { };
Z operator+(Z, Z) = delete;
void f()
{
float& x = int_if_addable<X>(0);
int& y = int_if_addable<Y>(0);
float& z = int_if_addable<Z>(0);
}
|
google
|
chromium
|
variadic96
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic96.C
| 418 |
utf_8
|
41e12174fa168c73046b0c0637085a21
|
// Origin: PR c++/41785
// { dg-options -std=c++0x }
struct a {};
template < typename T, typename ENCLOSING >
struct base;
template < typename... T >
struct derived
: public base< T, derived< T... > >...
{};
template < typename... T>
struct base< a, derived< T... > >
{
typedef derived< T... >
Derived;
};
int main()
{
derived< a > instance;
}
|
google
|
chromium
|
bind
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/bind.C
| 83 |
utf_8
|
50977a1e531cb1b5874af1663f7aa4f2
|
// { dg-options "--std=c++0x" }
struct S{};
void f(S&&);
int main()
{
f(S());
}
|
google
|
chromium
|
initlist10
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/initlist10.C
| 992 |
utf_8
|
73fd140acb60b79673309a4e733012ae
|
// PR c++/38380
// { dg-options "-std=gnu++0x" }
namespace std
{
struct atomic_bool
{
bool _M_i;
atomic_bool() = default;
~atomic_bool() = default;
atomic_bool(const atomic_bool&) = delete;
atomic_bool& operator=(const atomic_bool&) = delete;
explicit atomic_bool(bool __i) { _M_i = __i; }
operator bool() const volatile
{ return true; }
};
}
namespace __gnu_test
{
struct direct_list_initializable
{
template<typename _Ttype, typename _Tvalue>
void
operator()()
{
struct _Concept
{
void __constraint()
{
_Ttype __v1 = { }; // default ctor
_Ttype __v2 { __a }; // single-argument ctor
}
_Tvalue __a;
};
void (_Concept::*__x)() __attribute__((unused))
= &_Concept::__constraint;
}
};
}
int main()
{
__gnu_test::direct_list_initializable test;
test.operator()<std::atomic_bool, bool>();
return 0;
}
|
google
|
chromium
|
temp_default2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/temp_default2.C
| 300 |
utf_8
|
b0614ce472042e86627bab8a9917ae6c
|
// { dg-options "-std=c++0x" }
template <class T, class U = double>
void f(T t = 0, U u = 0);
void g()
{
f(1, 'c'); // f<int,char>(1,'c')
f(1); // f<int,double>(1,0)
f(); // { dg-error "no matching function" }
f<int>(); // f<int,double>(0,0)
f<int,char>(); // f<int,char>(0,0)
}
|
google
|
chromium
|
variadic-ex7
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic-ex7.C
| 595 |
utf_8
|
872a012c63a609887bf1eb5f52fcc0d7
|
// { dg-options "-std=gnu++0x" }
template<typename...> struct Tuple { };
template<typename... Types> char& g(Tuple<Types...>); // #1
template<typename T1, typename... Types> short& g(Tuple<T1, Types...>); // #2
template<typename T1, typename... Types> int& g(Tuple<T1, Types&...>); // #3
void f() {
// char& x1 = g(Tuple<>()); // calls #1
short& y1 = g(Tuple<int, float>()); // calls #2
// int& z1 = g(Tuple<int, float&>()); // calls #3
// int& z2 = g(Tuple<int>()); // calls #3
// int& z3 = g(Tuple<int>()); // calls #3
}
|
google
|
chromium
|
variadic43
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/variadic43.C
| 141 |
utf_8
|
3822f7c45c969832af7c5cc9cfc85b75
|
// { dg-options "-std=gnu++0x" }
template<typename... Args>
int f(const Args&...);
void g()
{
int (*fp)(const int&, const float&) = &f;
}
|
google
|
chromium
|
pr33996
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/pr33996.C
| 622 |
utf_8
|
858f5b1e4bec1cc54033874898b4c20f
|
// { dg-options "-std=c++0x" }
#define BUG
struct type
{
type() { }
type(const type&) { }
private:
type(type&&);
};
template<typename _Tp>
struct identity
{
typedef _Tp type;
};
template<typename _Tp>
inline _Tp&&
forward(typename identity<_Tp>::type&& __t)
{ return __t; }
struct vec
{
template<typename _Args>
void
bar(_Args&& __args)
#ifdef BUG
;
#else
{
type(forward<_Args>(__args));
}
#endif
};
#ifdef BUG
template<typename _Args>
void
vec::bar(_Args&& __args)
{
type(forward<_Args>(__args));
}
#endif
int main()
{
vec v;
type c;
}
|
google
|
chromium
|
rv5p
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/rv5p.C
| 41,030 |
utf_8
|
8b9713189146673d291c40fa2aa20a8a
|
// I, Howard Hinnant, hereby place this code in the public domain.
// Test overlaod resolution among referece types
// { dg-do compile }
// { dg-options "-std=c++0x" }
template <bool> struct sa;
template <> struct sa<true> {};
struct one {char x[1];};
struct two {char x[2];};
struct three {char x[3];};
struct four {char x[4];};
struct five {char x[5];};
struct six {char x[6];};
struct seven {char x[7];};
struct eight {char x[8];};
struct A
{
A();
A(const volatile A&&);
};
A source();
const A c_source();
volatile A v_source();
const volatile A cv_source();
// 5 at a time
one sink_5_12345( A&);
two sink_5_12345(const A&);
three sink_5_12345(volatile A&);
four sink_5_12345(const volatile A&);
five sink_5_12345( A&&);
int test5_12345()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12345(a)) == 1> t1;
sa<sizeof(sink_5_12345(ca)) == 2> t2;
sa<sizeof(sink_5_12345(va)) == 3> t3;
sa<sizeof(sink_5_12345(cva)) == 4> t4;
sa<sizeof(sink_5_12345(source())) == 5> t5;
sa<sizeof(sink_5_12345(c_source())) == 2> t6;
return 0;
}
one sink_5_12346( A&);
two sink_5_12346(const A&);
three sink_5_12346(volatile A&);
four sink_5_12346(const volatile A&);
six sink_5_12346(const A&&);
int test5_12346()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12346(a)) == 1> t1;
sa<sizeof(sink_5_12346(ca)) == 2> t2;
sa<sizeof(sink_5_12346(va)) == 3> t3;
sa<sizeof(sink_5_12346(cva)) == 4> t4;
sa<sizeof(sink_5_12346(source())) == 6> t5;
sa<sizeof(sink_5_12346(c_source())) == 6> t6;
return 0;
}
one sink_5_12347( A&);
two sink_5_12347(const A&);
three sink_5_12347(volatile A&);
four sink_5_12347(const volatile A&);
seven sink_5_12347(volatile A&&);
int test5_12347()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12347(a)) == 1> t1;
sa<sizeof(sink_5_12347(ca)) == 2> t2;
sa<sizeof(sink_5_12347(va)) == 3> t3;
sa<sizeof(sink_5_12347(cva)) == 4> t4;
sa<sizeof(sink_5_12347(source())) == 7> t5;
sa<sizeof(sink_5_12347(c_source())) == 2> t6;
sa<sizeof(sink_5_12347(v_source())) == 7> t7;
return 0;
}
one sink_5_12348( A&);
two sink_5_12348(const A&);
three sink_5_12348(volatile A&);
four sink_5_12348(const volatile A&);
eight sink_5_12348(const volatile A&&);
int test5_12348()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12348(a)) == 1> t1;
sa<sizeof(sink_5_12348(ca)) == 2> t2;
sa<sizeof(sink_5_12348(va)) == 3> t3;
sa<sizeof(sink_5_12348(cva)) == 4> t4;
sa<sizeof(sink_5_12348(source())) == 8> t5;
sa<sizeof(sink_5_12348(c_source())) == 8> t6;
sa<sizeof(sink_5_12348(v_source())) == 8> t7;
sa<sizeof(sink_5_12348(cv_source())) == 8> t8;
return 0;
}
one sink_5_12356( A&);
two sink_5_12356(const A&);
three sink_5_12356(volatile A&);
five sink_5_12356( A&&);
six sink_5_12356(const A&&);
int test5_12356()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12356(a)) == 1> t1;
sa<sizeof(sink_5_12356(ca)) == 2> t2;
sa<sizeof(sink_5_12356(va)) == 3> t3;
sa<sizeof(sink_5_12356(source())) == 5> t5;
sa<sizeof(sink_5_12356(c_source())) == 6> t6;
return 0;
}
one sink_5_12357( A&);
two sink_5_12357(const A&);
three sink_5_12357(volatile A&);
five sink_5_12357( A&&);
seven sink_5_12357(volatile A&&);
int test5_12357()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12357(a)) == 1> t1;
sa<sizeof(sink_5_12357(ca)) == 2> t2;
sa<sizeof(sink_5_12357(va)) == 3> t3;
sa<sizeof(sink_5_12357(source())) == 5> t5;
sa<sizeof(sink_5_12357(c_source())) == 2> t6;
sa<sizeof(sink_5_12357(v_source())) == 7> t7;
return 0;
}
one sink_5_12358( A&);
two sink_5_12358(const A&);
three sink_5_12358(volatile A&);
five sink_5_12358( A&&);
eight sink_5_12358(const volatile A&&);
int test5_12358()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12358(a)) == 1> t1;
sa<sizeof(sink_5_12358(ca)) == 2> t2;
sa<sizeof(sink_5_12358(va)) == 3> t3;
sa<sizeof(sink_5_12358(cva)) == 8> t4;
sa<sizeof(sink_5_12358(source())) == 5> t5;
sa<sizeof(sink_5_12358(c_source())) == 8> t6;
sa<sizeof(sink_5_12358(v_source())) == 8> t7;
sa<sizeof(sink_5_12358(cv_source())) == 8> t8;
return 0;
}
one sink_5_12367( A&);
two sink_5_12367(const A&);
three sink_5_12367(volatile A&);
six sink_5_12367(const A&&);
seven sink_5_12367(volatile A&&);
int test5_12367()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12367(a)) == 1> t1;
sa<sizeof(sink_5_12367(ca)) == 2> t2;
sa<sizeof(sink_5_12367(va)) == 3> t3;
sa<sizeof(sink_5_12367(c_source())) == 6> t6;
sa<sizeof(sink_5_12367(v_source())) == 7> t7;
return 0;
}
one sink_5_12368( A&);
two sink_5_12368(const A&);
three sink_5_12368(volatile A&);
six sink_5_12368(const A&&);
eight sink_5_12368(const volatile A&&);
int test5_12368()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12368(a)) == 1> t1;
sa<sizeof(sink_5_12368(ca)) == 2> t2;
sa<sizeof(sink_5_12368(va)) == 3> t3;
sa<sizeof(sink_5_12368(cva)) == 8> t4;
sa<sizeof(sink_5_12368(source())) == 6> t5;
sa<sizeof(sink_5_12368(c_source())) == 6> t6;
sa<sizeof(sink_5_12368(v_source())) == 8> t7;
sa<sizeof(sink_5_12368(cv_source())) == 8> t8;
return 0;
}
one sink_5_12378( A&);
two sink_5_12378(const A&);
three sink_5_12378(volatile A&);
seven sink_5_12378(volatile A&&);
eight sink_5_12378(const volatile A&&);
int test5_12378()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12378(a)) == 1> t1;
sa<sizeof(sink_5_12378(ca)) == 2> t2;
sa<sizeof(sink_5_12378(va)) == 3> t3;
sa<sizeof(sink_5_12378(cva)) == 8> t4;
sa<sizeof(sink_5_12378(source())) == 7> t5;
sa<sizeof(sink_5_12378(c_source())) == 8> t6;
sa<sizeof(sink_5_12378(v_source())) == 7> t7;
sa<sizeof(sink_5_12378(cv_source())) == 8> t8;
return 0;
}
one sink_5_12456( A&);
two sink_5_12456(const A&);
four sink_5_12456(const volatile A&);
five sink_5_12456( A&&);
six sink_5_12456(const A&&);
int test5_12456()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12456(a)) == 1> t1;
sa<sizeof(sink_5_12456(ca)) == 2> t2;
sa<sizeof(sink_5_12456(va)) == 4> t3;
sa<sizeof(sink_5_12456(cva)) == 4> t4;
sa<sizeof(sink_5_12456(source())) == 5> t5;
sa<sizeof(sink_5_12456(c_source())) == 6> t6;
return 0;
}
one sink_5_12457( A&);
two sink_5_12457(const A&);
four sink_5_12457(const volatile A&);
five sink_5_12457( A&&);
seven sink_5_12457(volatile A&&);
int test5_12457()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12457(a)) == 1> t1;
sa<sizeof(sink_5_12457(ca)) == 2> t2;
sa<sizeof(sink_5_12457(va)) == 4> t3;
sa<sizeof(sink_5_12457(cva)) == 4> t4;
sa<sizeof(sink_5_12457(source())) == 5> t5;
sa<sizeof(sink_5_12457(c_source())) == 2> t6;
sa<sizeof(sink_5_12457(v_source())) == 7> t7;
return 0;
}
one sink_5_12458( A&);
two sink_5_12458(const A&);
four sink_5_12458(const volatile A&);
five sink_5_12458( A&&);
eight sink_5_12458(const volatile A&&);
int test5_12458()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12458(a)) == 1> t1;
sa<sizeof(sink_5_12458(ca)) == 2> t2;
sa<sizeof(sink_5_12458(va)) == 4> t3;
sa<sizeof(sink_5_12458(cva)) == 4> t4;
sa<sizeof(sink_5_12458(source())) == 5> t5;
sa<sizeof(sink_5_12458(c_source())) == 8> t6;
sa<sizeof(sink_5_12458(v_source())) == 8> t7;
sa<sizeof(sink_5_12458(cv_source())) == 8> t8;
return 0;
}
one sink_5_12467( A&);
two sink_5_12467(const A&);
four sink_5_12467(const volatile A&);
six sink_5_12467(const A&&);
seven sink_5_12467(volatile A&&);
int test5_12467()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12467(a)) == 1> t1;
sa<sizeof(sink_5_12467(ca)) == 2> t2;
sa<sizeof(sink_5_12467(va)) == 4> t3;
sa<sizeof(sink_5_12467(cva)) == 4> t4;
sa<sizeof(sink_5_12467(c_source())) == 6> t6;
sa<sizeof(sink_5_12467(v_source())) == 7> t7;
return 0;
}
one sink_5_12468( A&);
two sink_5_12468(const A&);
four sink_5_12468(const volatile A&);
six sink_5_12468(const A&&);
eight sink_5_12468(const volatile A&&);
int test5_12468()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12468(a)) == 1> t1;
sa<sizeof(sink_5_12468(ca)) == 2> t2;
sa<sizeof(sink_5_12468(va)) == 4> t3;
sa<sizeof(sink_5_12468(cva)) == 4> t4;
sa<sizeof(sink_5_12468(source())) == 6> t5;
sa<sizeof(sink_5_12468(c_source())) == 6> t6;
sa<sizeof(sink_5_12468(v_source())) == 8> t7;
sa<sizeof(sink_5_12468(cv_source())) == 8> t8;
return 0;
}
one sink_5_12478( A&);
two sink_5_12478(const A&);
four sink_5_12478(const volatile A&);
seven sink_5_12478(volatile A&&);
eight sink_5_12478(const volatile A&&);
int test5_12478()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12478(a)) == 1> t1;
sa<sizeof(sink_5_12478(ca)) == 2> t2;
sa<sizeof(sink_5_12478(va)) == 4> t3;
sa<sizeof(sink_5_12478(cva)) == 4> t4;
sa<sizeof(sink_5_12478(source())) == 7> t5;
sa<sizeof(sink_5_12478(c_source())) == 8> t6;
sa<sizeof(sink_5_12478(v_source())) == 7> t7;
sa<sizeof(sink_5_12478(cv_source())) == 8> t8;
return 0;
}
one sink_5_12567( A&);
two sink_5_12567(const A&);
five sink_5_12567( A&&);
six sink_5_12567(const A&&);
seven sink_5_12567(volatile A&&);
int test5_12567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12567(a)) == 1> t1;
sa<sizeof(sink_5_12567(ca)) == 2> t2;
sa<sizeof(sink_5_12567(va)) == 7> t3;
sa<sizeof(sink_5_12567(source())) == 5> t5;
sa<sizeof(sink_5_12567(c_source())) == 6> t6;
sa<sizeof(sink_5_12567(v_source())) == 7> t7;
return 0;
}
one sink_5_12568( A&);
two sink_5_12568(const A&);
five sink_5_12568( A&&);
six sink_5_12568(const A&&);
eight sink_5_12568(const volatile A&&);
int test5_12568()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12568(a)) == 1> t1;
sa<sizeof(sink_5_12568(ca)) == 2> t2;
sa<sizeof(sink_5_12568(va)) == 8> t3;
sa<sizeof(sink_5_12568(cva)) == 8> t4;
sa<sizeof(sink_5_12568(source())) == 5> t5;
sa<sizeof(sink_5_12568(c_source())) == 6> t6;
sa<sizeof(sink_5_12568(v_source())) == 8> t7;
sa<sizeof(sink_5_12568(cv_source())) == 8> t8;
return 0;
}
one sink_5_12578( A&);
two sink_5_12578(const A&);
five sink_5_12578( A&&);
seven sink_5_12578(volatile A&&);
eight sink_5_12578(const volatile A&&);
int test5_12578()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12578(a)) == 1> t1;
sa<sizeof(sink_5_12578(ca)) == 2> t2;
sa<sizeof(sink_5_12578(va)) == 7> t3;
sa<sizeof(sink_5_12578(cva)) == 8> t4;
sa<sizeof(sink_5_12578(source())) == 5> t5;
sa<sizeof(sink_5_12578(c_source())) == 8> t6;
sa<sizeof(sink_5_12578(v_source())) == 7> t7;
sa<sizeof(sink_5_12578(cv_source())) == 8> t8;
return 0;
}
one sink_5_12678( A&);
two sink_5_12678(const A&);
six sink_5_12678(const A&&);
seven sink_5_12678(volatile A&&);
eight sink_5_12678(const volatile A&&);
int test5_12678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_12678(a)) == 1> t1;
sa<sizeof(sink_5_12678(ca)) == 2> t2;
sa<sizeof(sink_5_12678(va)) == 7> t3;
sa<sizeof(sink_5_12678(cva)) == 8> t4;
sa<sizeof(sink_5_12678(c_source())) == 6> t6;
sa<sizeof(sink_5_12678(v_source())) == 7> t7;
sa<sizeof(sink_5_12678(cv_source())) == 8> t8;
return 0;
}
one sink_5_13456( A&);
three sink_5_13456(volatile A&);
four sink_5_13456(const volatile A&);
five sink_5_13456( A&&);
six sink_5_13456(const A&&);
int test5_13456()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13456(a)) == 1> t1;
sa<sizeof(sink_5_13456(ca)) == 4> t2;
sa<sizeof(sink_5_13456(va)) == 3> t3;
sa<sizeof(sink_5_13456(cva)) == 4> t4;
sa<sizeof(sink_5_13456(source())) == 5> t5;
sa<sizeof(sink_5_13456(c_source())) == 6> t6;
return 0;
}
one sink_5_13457( A&);
three sink_5_13457(volatile A&);
four sink_5_13457(const volatile A&);
five sink_5_13457( A&&);
seven sink_5_13457(volatile A&&);
int test5_13457()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13457(a)) == 1> t1;
sa<sizeof(sink_5_13457(ca)) == 4> t2;
sa<sizeof(sink_5_13457(va)) == 3> t3;
sa<sizeof(sink_5_13457(cva)) == 4> t4;
sa<sizeof(sink_5_13457(source())) == 5> t5;
sa<sizeof(sink_5_13457(v_source())) == 7> t7;
return 0;
}
one sink_5_13458( A&);
three sink_5_13458(volatile A&);
four sink_5_13458(const volatile A&);
five sink_5_13458( A&&);
eight sink_5_13458(const volatile A&&);
int test5_13458()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13458(a)) == 1> t1;
sa<sizeof(sink_5_13458(ca)) == 4> t2;
sa<sizeof(sink_5_13458(va)) == 3> t3;
sa<sizeof(sink_5_13458(cva)) == 4> t4;
sa<sizeof(sink_5_13458(source())) == 5> t5;
sa<sizeof(sink_5_13458(c_source())) == 8> t6;
sa<sizeof(sink_5_13458(v_source())) == 8> t7;
sa<sizeof(sink_5_13458(cv_source())) == 8> t8;
return 0;
}
one sink_5_13467( A&);
three sink_5_13467(volatile A&);
four sink_5_13467(const volatile A&);
six sink_5_13467(const A&&);
seven sink_5_13467(volatile A&&);
int test5_13467()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13467(a)) == 1> t1;
sa<sizeof(sink_5_13467(ca)) == 4> t2;
sa<sizeof(sink_5_13467(va)) == 3> t3;
sa<sizeof(sink_5_13467(cva)) == 4> t4;
sa<sizeof(sink_5_13467(c_source())) == 6> t6;
sa<sizeof(sink_5_13467(v_source())) == 7> t7;
return 0;
}
one sink_5_13468( A&);
three sink_5_13468(volatile A&);
four sink_5_13468(const volatile A&);
six sink_5_13468(const A&&);
eight sink_5_13468(const volatile A&&);
int test5_13468()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13468(a)) == 1> t1;
sa<sizeof(sink_5_13468(ca)) == 4> t2;
sa<sizeof(sink_5_13468(va)) == 3> t3;
sa<sizeof(sink_5_13468(cva)) == 4> t4;
sa<sizeof(sink_5_13468(source())) == 6> t5;
sa<sizeof(sink_5_13468(c_source())) == 6> t6;
sa<sizeof(sink_5_13468(v_source())) == 8> t7;
sa<sizeof(sink_5_13468(cv_source())) == 8> t8;
return 0;
}
one sink_5_13478( A&);
three sink_5_13478(volatile A&);
four sink_5_13478(const volatile A&);
seven sink_5_13478(volatile A&&);
eight sink_5_13478(const volatile A&&);
int test5_13478()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13478(a)) == 1> t1;
sa<sizeof(sink_5_13478(ca)) == 4> t2;
sa<sizeof(sink_5_13478(va)) == 3> t3;
sa<sizeof(sink_5_13478(cva)) == 4> t4;
sa<sizeof(sink_5_13478(source())) == 7> t5;
sa<sizeof(sink_5_13478(c_source())) == 8> t6;
sa<sizeof(sink_5_13478(v_source())) == 7> t7;
sa<sizeof(sink_5_13478(cv_source())) == 8> t8;
return 0;
}
one sink_5_13567( A&);
three sink_5_13567(volatile A&);
five sink_5_13567( A&&);
six sink_5_13567(const A&&);
seven sink_5_13567(volatile A&&);
int test5_13567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13567(a)) == 1> t1;
sa<sizeof(sink_5_13567(ca)) == 6> t2;
sa<sizeof(sink_5_13567(va)) == 3> t3;
sa<sizeof(sink_5_13567(source())) == 5> t5;
sa<sizeof(sink_5_13567(c_source())) == 6> t6;
sa<sizeof(sink_5_13567(v_source())) == 7> t7;
return 0;
}
one sink_5_13568( A&);
three sink_5_13568(volatile A&);
five sink_5_13568( A&&);
six sink_5_13568(const A&&);
eight sink_5_13568(const volatile A&&);
int test5_13568()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13568(a)) == 1> t1;
sa<sizeof(sink_5_13568(ca)) == 6> t2;
sa<sizeof(sink_5_13568(va)) == 3> t3;
sa<sizeof(sink_5_13568(cva)) == 8> t4;
sa<sizeof(sink_5_13568(source())) == 5> t5;
sa<sizeof(sink_5_13568(c_source())) == 6> t6;
sa<sizeof(sink_5_13568(v_source())) == 8> t7;
sa<sizeof(sink_5_13568(cv_source())) == 8> t8;
return 0;
}
one sink_5_13578( A&);
three sink_5_13578(volatile A&);
five sink_5_13578( A&&);
seven sink_5_13578(volatile A&&);
eight sink_5_13578(const volatile A&&);
int test5_13578()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13578(a)) == 1> t1;
sa<sizeof(sink_5_13578(ca)) == 8> t2;
sa<sizeof(sink_5_13578(va)) == 3> t3;
sa<sizeof(sink_5_13578(cva)) == 8> t4;
sa<sizeof(sink_5_13578(source())) == 5> t5;
sa<sizeof(sink_5_13578(c_source())) == 8> t6;
sa<sizeof(sink_5_13578(v_source())) == 7> t7;
sa<sizeof(sink_5_13578(cv_source())) == 8> t8;
return 0;
}
one sink_5_13678( A&);
three sink_5_13678(volatile A&);
six sink_5_13678(const A&&);
seven sink_5_13678(volatile A&&);
eight sink_5_13678(const volatile A&&);
int test5_13678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_13678(a)) == 1> t1;
sa<sizeof(sink_5_13678(ca)) == 6> t2;
sa<sizeof(sink_5_13678(va)) == 3> t3;
sa<sizeof(sink_5_13678(cva)) == 8> t4;
sa<sizeof(sink_5_13678(c_source())) == 6> t6;
sa<sizeof(sink_5_13678(v_source())) == 7> t7;
sa<sizeof(sink_5_13678(cv_source())) == 8> t8;
return 0;
}
one sink_5_14567( A&);
four sink_5_14567(const volatile A&);
five sink_5_14567( A&&);
six sink_5_14567(const A&&);
seven sink_5_14567(volatile A&&);
int test5_14567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_14567(a)) == 1> t1;
sa<sizeof(sink_5_14567(ca)) == 4> t2;
sa<sizeof(sink_5_14567(va)) == 4> t3;
sa<sizeof(sink_5_14567(cva)) == 4> t4;
sa<sizeof(sink_5_14567(source())) == 5> t5;
sa<sizeof(sink_5_14567(c_source())) == 6> t6;
sa<sizeof(sink_5_14567(v_source())) == 7> t7;
return 0;
}
one sink_5_14568( A&);
four sink_5_14568(const volatile A&);
five sink_5_14568( A&&);
six sink_5_14568(const A&&);
eight sink_5_14568(const volatile A&&);
int test5_14568()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_14568(a)) == 1> t1;
sa<sizeof(sink_5_14568(ca)) == 4> t2;
sa<sizeof(sink_5_14568(va)) == 4> t3;
sa<sizeof(sink_5_14568(cva)) == 4> t4;
sa<sizeof(sink_5_14568(source())) == 5> t5;
sa<sizeof(sink_5_14568(c_source())) == 6> t6;
sa<sizeof(sink_5_14568(v_source())) == 8> t7;
sa<sizeof(sink_5_14568(cv_source())) == 8> t8;
return 0;
}
one sink_5_14578( A&);
four sink_5_14578(const volatile A&);
five sink_5_14578( A&&);
seven sink_5_14578(volatile A&&);
eight sink_5_14578(const volatile A&&);
int test5_14578()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_14578(a)) == 1> t1;
sa<sizeof(sink_5_14578(ca)) == 4> t2;
sa<sizeof(sink_5_14578(va)) == 4> t3;
sa<sizeof(sink_5_14578(cva)) == 4> t4;
sa<sizeof(sink_5_14578(source())) == 5> t5;
sa<sizeof(sink_5_14578(c_source())) == 8> t6;
sa<sizeof(sink_5_14578(v_source())) == 7> t7;
sa<sizeof(sink_5_14578(cv_source())) == 8> t8;
return 0;
}
one sink_5_14678( A&);
four sink_5_14678(const volatile A&);
six sink_5_14678(const A&&);
seven sink_5_14678(volatile A&&);
eight sink_5_14678(const volatile A&&);
int test5_14678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_14678(a)) == 1> t1;
sa<sizeof(sink_5_14678(ca)) == 4> t2;
sa<sizeof(sink_5_14678(va)) == 4> t3;
sa<sizeof(sink_5_14678(cva)) == 4> t4;
sa<sizeof(sink_5_14678(c_source())) == 6> t6;
sa<sizeof(sink_5_14678(v_source())) == 7> t7;
sa<sizeof(sink_5_14678(cv_source())) == 8> t8;
return 0;
}
one sink_5_15678( A&);
five sink_5_15678( A&&);
six sink_5_15678(const A&&);
seven sink_5_15678(volatile A&&);
eight sink_5_15678(const volatile A&&);
int test5_15678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_15678(a)) == 1> t1;
sa<sizeof(sink_5_15678(ca)) == 6> t2;
sa<sizeof(sink_5_15678(va)) == 7> t3;
sa<sizeof(sink_5_15678(cva)) == 8> t4;
sa<sizeof(sink_5_15678(source())) == 5> t5;
sa<sizeof(sink_5_15678(c_source())) == 6> t6;
sa<sizeof(sink_5_15678(v_source())) == 7> t7;
sa<sizeof(sink_5_15678(cv_source())) == 8> t8;
return 0;
}
two sink_5_23456(const A&);
three sink_5_23456(volatile A&);
four sink_5_23456(const volatile A&);
five sink_5_23456( A&&);
six sink_5_23456(const A&&);
int test5_23456()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23456(ca)) == 2> t2;
sa<sizeof(sink_5_23456(va)) == 3> t3;
sa<sizeof(sink_5_23456(cva)) == 4> t4;
sa<sizeof(sink_5_23456(source())) == 5> t5;
sa<sizeof(sink_5_23456(c_source())) == 6> t6;
return 0;
}
two sink_5_23457(const A&);
three sink_5_23457(volatile A&);
four sink_5_23457(const volatile A&);
five sink_5_23457( A&&);
seven sink_5_23457(volatile A&&);
int test5_23457()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23457(ca)) == 2> t2;
sa<sizeof(sink_5_23457(va)) == 3> t3;
sa<sizeof(sink_5_23457(cva)) == 4> t4;
sa<sizeof(sink_5_23457(source())) == 5> t5;
sa<sizeof(sink_5_23457(c_source())) == 2> t6;
sa<sizeof(sink_5_23457(v_source())) == 7> t7;
return 0;
}
two sink_5_23458(const A&);
three sink_5_23458(volatile A&);
four sink_5_23458(const volatile A&);
five sink_5_23458( A&&);
eight sink_5_23458(const volatile A&&);
int test5_23458()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23458(ca)) == 2> t2;
sa<sizeof(sink_5_23458(va)) == 3> t3;
sa<sizeof(sink_5_23458(cva)) == 4> t4;
sa<sizeof(sink_5_23458(source())) == 5> t5;
sa<sizeof(sink_5_23458(c_source())) == 8> t6;
sa<sizeof(sink_5_23458(v_source())) == 8> t7;
sa<sizeof(sink_5_23458(cv_source())) == 8> t8;
return 0;
}
two sink_5_23467(const A&);
three sink_5_23467(volatile A&);
four sink_5_23467(const volatile A&);
six sink_5_23467(const A&&);
seven sink_5_23467(volatile A&&);
int test5_23467()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23467(ca)) == 2> t2;
sa<sizeof(sink_5_23467(va)) == 3> t3;
sa<sizeof(sink_5_23467(cva)) == 4> t4;
sa<sizeof(sink_5_23467(c_source())) == 6> t6;
sa<sizeof(sink_5_23467(v_source())) == 7> t7;
return 0;
}
two sink_5_23468(const A&);
three sink_5_23468(volatile A&);
four sink_5_23468(const volatile A&);
six sink_5_23468(const A&&);
eight sink_5_23468(const volatile A&&);
int test5_23468()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23468(ca)) == 2> t2;
sa<sizeof(sink_5_23468(va)) == 3> t3;
sa<sizeof(sink_5_23468(cva)) == 4> t4;
sa<sizeof(sink_5_23468(source())) == 6> t5;
sa<sizeof(sink_5_23468(c_source())) == 6> t6;
sa<sizeof(sink_5_23468(v_source())) == 8> t7;
sa<sizeof(sink_5_23468(cv_source())) == 8> t8;
return 0;
}
two sink_5_23478(const A&);
three sink_5_23478(volatile A&);
four sink_5_23478(const volatile A&);
seven sink_5_23478(volatile A&&);
eight sink_5_23478(const volatile A&&);
int test5_23478()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23478(ca)) == 2> t2;
sa<sizeof(sink_5_23478(va)) == 3> t3;
sa<sizeof(sink_5_23478(cva)) == 4> t4;
sa<sizeof(sink_5_23478(source())) == 7> t5;
sa<sizeof(sink_5_23478(c_source())) == 8> t6;
sa<sizeof(sink_5_23478(v_source())) == 7> t7;
sa<sizeof(sink_5_23478(cv_source())) == 8> t8;
return 0;
}
two sink_5_23567(const A&);
three sink_5_23567(volatile A&);
five sink_5_23567( A&&);
six sink_5_23567(const A&&);
seven sink_5_23567(volatile A&&);
int test5_23567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23567(ca)) == 2> t2;
sa<sizeof(sink_5_23567(va)) == 3> t3;
sa<sizeof(sink_5_23567(source())) == 5> t5;
sa<sizeof(sink_5_23567(c_source())) == 6> t6;
sa<sizeof(sink_5_23567(v_source())) == 7> t7;
return 0;
}
two sink_5_23568(const A&);
three sink_5_23568(volatile A&);
five sink_5_23568( A&&);
six sink_5_23568(const A&&);
eight sink_5_23568(const volatile A&&);
int test5_23568()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23568(ca)) == 2> t2;
sa<sizeof(sink_5_23568(va)) == 3> t3;
sa<sizeof(sink_5_23568(cva)) == 8> t4;
sa<sizeof(sink_5_23568(source())) == 5> t5;
sa<sizeof(sink_5_23568(c_source())) == 6> t6;
sa<sizeof(sink_5_23568(v_source())) == 8> t7;
sa<sizeof(sink_5_23568(cv_source())) == 8> t8;
return 0;
}
two sink_5_23578(const A&);
three sink_5_23578(volatile A&);
five sink_5_23578( A&&);
seven sink_5_23578(volatile A&&);
eight sink_5_23578(const volatile A&&);
int test5_23578()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23578(ca)) == 2> t2;
sa<sizeof(sink_5_23578(va)) == 3> t3;
sa<sizeof(sink_5_23578(cva)) == 8> t4;
sa<sizeof(sink_5_23578(source())) == 5> t5;
sa<sizeof(sink_5_23578(c_source())) == 8> t6;
sa<sizeof(sink_5_23578(v_source())) == 7> t7;
sa<sizeof(sink_5_23578(cv_source())) == 8> t8;
return 0;
}
two sink_5_23678(const A&);
three sink_5_23678(volatile A&);
six sink_5_23678(const A&&);
seven sink_5_23678(volatile A&&);
eight sink_5_23678(const volatile A&&);
int test5_23678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_23678(ca)) == 2> t2;
sa<sizeof(sink_5_23678(va)) == 3> t3;
sa<sizeof(sink_5_23678(cva)) == 8> t4;
sa<sizeof(sink_5_23678(c_source())) == 6> t6;
sa<sizeof(sink_5_23678(v_source())) == 7> t7;
sa<sizeof(sink_5_23678(cv_source())) == 8> t8;
return 0;
}
two sink_5_24567(const A&);
four sink_5_24567(const volatile A&);
five sink_5_24567( A&&);
six sink_5_24567(const A&&);
seven sink_5_24567(volatile A&&);
int test5_24567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_24567(a)) == 2> t1;
sa<sizeof(sink_5_24567(ca)) == 2> t2;
sa<sizeof(sink_5_24567(va)) == 4> t3;
sa<sizeof(sink_5_24567(cva)) == 4> t4;
sa<sizeof(sink_5_24567(source())) == 5> t5;
sa<sizeof(sink_5_24567(c_source())) == 6> t6;
sa<sizeof(sink_5_24567(v_source())) == 7> t7;
return 0;
}
two sink_5_24568(const A&);
four sink_5_24568(const volatile A&);
five sink_5_24568( A&&);
six sink_5_24568(const A&&);
eight sink_5_24568(const volatile A&&);
int test5_24568()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_24568(a)) == 2> t1;
sa<sizeof(sink_5_24568(ca)) == 2> t2;
sa<sizeof(sink_5_24568(va)) == 4> t3;
sa<sizeof(sink_5_24568(cva)) == 4> t4;
sa<sizeof(sink_5_24568(source())) == 5> t5;
sa<sizeof(sink_5_24568(c_source())) == 6> t6;
sa<sizeof(sink_5_24568(v_source())) == 8> t7;
sa<sizeof(sink_5_24568(cv_source())) == 8> t8;
return 0;
}
two sink_5_24578(const A&);
four sink_5_24578(const volatile A&);
five sink_5_24578( A&&);
seven sink_5_24578(volatile A&&);
eight sink_5_24578(const volatile A&&);
int test5_24578()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_24578(a)) == 2> t1;
sa<sizeof(sink_5_24578(ca)) == 2> t2;
sa<sizeof(sink_5_24578(va)) == 4> t3;
sa<sizeof(sink_5_24578(cva)) == 4> t4;
sa<sizeof(sink_5_24578(source())) == 5> t5;
sa<sizeof(sink_5_24578(c_source())) == 8> t6;
sa<sizeof(sink_5_24578(v_source())) == 7> t7;
sa<sizeof(sink_5_24578(cv_source())) == 8> t8;
return 0;
}
two sink_5_24678(const A&);
four sink_5_24678(const volatile A&);
six sink_5_24678(const A&&);
seven sink_5_24678(volatile A&&);
eight sink_5_24678(const volatile A&&);
int test5_24678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_24678(a)) == 2> t1;
sa<sizeof(sink_5_24678(ca)) == 2> t2;
sa<sizeof(sink_5_24678(va)) == 4> t3;
sa<sizeof(sink_5_24678(cva)) == 4> t4;
sa<sizeof(sink_5_24678(c_source())) == 6> t6;
sa<sizeof(sink_5_24678(v_source())) == 7> t7;
sa<sizeof(sink_5_24678(cv_source())) == 8> t8;
return 0;
}
two sink_5_25678(const A&);
five sink_5_25678( A&&);
six sink_5_25678(const A&&);
seven sink_5_25678(volatile A&&);
eight sink_5_25678(const volatile A&&);
int test5_25678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_25678(a)) == 2> t1;
sa<sizeof(sink_5_25678(ca)) == 2> t2;
sa<sizeof(sink_5_25678(va)) == 7> t3;
sa<sizeof(sink_5_25678(cva)) == 8> t4;
sa<sizeof(sink_5_25678(source())) == 5> t5;
sa<sizeof(sink_5_25678(c_source())) == 6> t6;
sa<sizeof(sink_5_25678(v_source())) == 7> t7;
sa<sizeof(sink_5_25678(cv_source())) == 8> t8;
return 0;
}
three sink_5_34567(volatile A&);
four sink_5_34567(const volatile A&);
five sink_5_34567( A&&);
six sink_5_34567(const A&&);
seven sink_5_34567(volatile A&&);
int test5_34567()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_34567(a)) == 3> t1;
sa<sizeof(sink_5_34567(ca)) == 4> t2;
sa<sizeof(sink_5_34567(va)) == 3> t3;
sa<sizeof(sink_5_34567(cva)) == 4> t4;
sa<sizeof(sink_5_34567(source())) == 5> t5;
sa<sizeof(sink_5_34567(c_source())) == 6> t6;
sa<sizeof(sink_5_34567(v_source())) == 7> t7;
return 0;
}
three sink_5_34568(volatile A&);
four sink_5_34568(const volatile A&);
five sink_5_34568( A&&);
six sink_5_34568(const A&&);
eight sink_5_34568(const volatile A&&);
int test5_34568()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_34568(a)) == 3> t1;
sa<sizeof(sink_5_34568(ca)) == 4> t2;
sa<sizeof(sink_5_34568(va)) == 3> t3;
sa<sizeof(sink_5_34568(cva)) == 4> t4;
sa<sizeof(sink_5_34568(source())) == 5> t5;
sa<sizeof(sink_5_34568(c_source())) == 6> t6;
sa<sizeof(sink_5_34568(v_source())) == 8> t7;
sa<sizeof(sink_5_34568(cv_source())) == 8> t8;
return 0;
}
three sink_5_34578(volatile A&);
four sink_5_34578(const volatile A&);
five sink_5_34578( A&&);
seven sink_5_34578(volatile A&&);
eight sink_5_34578(const volatile A&&);
int test5_34578()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_34578(a)) == 3> t1;
sa<sizeof(sink_5_34578(ca)) == 4> t2;
sa<sizeof(sink_5_34578(va)) == 3> t3;
sa<sizeof(sink_5_34578(cva)) == 4> t4;
sa<sizeof(sink_5_34578(source())) == 5> t5;
sa<sizeof(sink_5_34578(c_source())) == 8> t6;
sa<sizeof(sink_5_34578(v_source())) == 7> t7;
sa<sizeof(sink_5_34578(cv_source())) == 8> t8;
return 0;
}
three sink_5_34678(volatile A&);
four sink_5_34678(const volatile A&);
six sink_5_34678(const A&&);
seven sink_5_34678(volatile A&&);
eight sink_5_34678(const volatile A&&);
int test5_34678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_34678(a)) == 3> t1;
sa<sizeof(sink_5_34678(ca)) == 4> t2;
sa<sizeof(sink_5_34678(va)) == 3> t3;
sa<sizeof(sink_5_34678(cva)) == 4> t4;
sa<sizeof(sink_5_34678(c_source())) == 6> t6;
sa<sizeof(sink_5_34678(v_source())) == 7> t7;
sa<sizeof(sink_5_34678(cv_source())) == 8> t8;
return 0;
}
three sink_5_35678(volatile A&);
five sink_5_35678( A&&);
six sink_5_35678(const A&&);
seven sink_5_35678(volatile A&&);
eight sink_5_35678(const volatile A&&);
int test5_35678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_35678(a)) == 3> t1;
sa<sizeof(sink_5_35678(ca)) == 6> t2;
sa<sizeof(sink_5_35678(va)) == 3> t3;
sa<sizeof(sink_5_35678(cva)) == 8> t4;
sa<sizeof(sink_5_35678(source())) == 5> t5;
sa<sizeof(sink_5_35678(c_source())) == 6> t6;
sa<sizeof(sink_5_35678(v_source())) == 7> t7;
sa<sizeof(sink_5_35678(cv_source())) == 8> t8;
return 0;
}
four sink_5_45678(const volatile A&);
five sink_5_45678( A&&);
six sink_5_45678(const A&&);
seven sink_5_45678(volatile A&&);
eight sink_5_45678(const volatile A&&);
int test5_45678()
{
A a;
const A ca = a;
volatile A va;
const volatile A cva = a;
sa<sizeof(sink_5_45678(a)) == 4> t1;
sa<sizeof(sink_5_45678(ca)) == 4> t2;
sa<sizeof(sink_5_45678(va)) == 4> t3;
sa<sizeof(sink_5_45678(cva)) == 4> t4;
sa<sizeof(sink_5_45678(source())) == 5> t5;
sa<sizeof(sink_5_45678(c_source())) == 6> t6;
sa<sizeof(sink_5_45678(v_source())) == 7> t7;
sa<sizeof(sink_5_45678(cv_source())) == 8> t8;
return 0;
}
int main()
{
return test5_12345() + test5_12346() + test5_12347() + test5_12348() +
test5_12356() + test5_12357() + test5_12358() + test5_12367() +
test5_12368() + test5_12378() + test5_12456() + test5_12457() +
test5_12458() + test5_12467() + test5_12468() + test5_12478() +
test5_12567() + test5_12568() + test5_12578() + test5_12678() +
test5_13456() + test5_13457() + test5_13458() + test5_13467() +
test5_13468() + test5_13478() + test5_13567() + test5_13568() +
test5_13578() + test5_13678() + test5_14567() + test5_14568() +
test5_14578() + test5_14678() + test5_15678() + test5_23456() +
test5_23457() + test5_23458() + test5_23467() + test5_23468() +
test5_23478() + test5_23567() + test5_23568() + test5_23578() +
test5_23678() + test5_24567() + test5_24568() + test5_24578() +
test5_24678() + test5_25678() + test5_34567() + test5_34568() +
test5_34578() + test5_34678() + test5_35678() + test5_45678();
}
|
google
|
chromium
|
defaulted7
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/defaulted7.C
| 288 |
utf_8
|
7ce42a1717ccdfef065fa2abb34b230c
|
// PR c++/38701, 38702
// { dg-options "-std=c++0x" }
void foo() = default; // { dg-error "cannot be defaulted" }
namespace
{
void bar() = default; // { dg-error "cannot be defaulted" }
}
enum E { e };
E& operator |= (E&, const E&) = default; // { dg-error "cannot be defaulted" }
|
google
|
chromium
|
initlist11
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/initlist11.C
| 203 |
utf_8
|
8dbe19ce3d5e8c97798e92453af88063
|
// PR c++/38684
// { dg-options "-std=c++0x" }
#include <initializer_list>
struct Y {};
struct X : Y {
X(std::initializer_list<int>) {}
};
struct A {
X v;
};
int main() {
A a{ {1,2,3} };
}
|
google
|
chromium
|
vt-34219-2
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/vt-34219-2.C
| 459 |
utf_8
|
2919779431c1c9526a08be75d89b5c3b
|
// { dg-options "-std=c++0x" }
template<template<typename... T> class Comp, typename... T> void f( T... Value)
{
static_assert( Comp<T>::value > 0, "" ); // { dg-error "parameter packs|T" }
}
template<template<typename... T> class Comp, typename... T> void g( T... Value)
{
static_assert( Comp<T...>::value > 0, "" );
}
template <typename... T>
struct Foo
{
static const int value=1;
};
int main()
{
f<Foo>( 2 );
g<Foo>( 2 );
}
|
google
|
chromium
|
initlist21
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/initlist21.C
| 366 |
utf_8
|
1a171945afcdcbc357d5fbf41918feb6
|
// PR c++/40689
// { dg-options "-std=c++0x" }
class X
{
public:
X(): data {1,2} {} // { dg-error "too many initializers" }
private:
const short data[1];
};
int f(int n)
{
const float * pData = new const float[1] { 1.5, 2.5 }; // { dg-error "too many initializers" }
pData = new const float[n] { 1.5, 2.5 }; // { dg-warning "array size" }
return 0;
}
|
google
|
chromium
|
collapse-bug
|
.C
|
native_client/nacl-gcc/gcc/testsuite/g++.dg/cpp0x/collapse-bug.C
| 375 |
utf_8
|
7a2dbf79945c55067480b8e1f8c3a065
|
// { dg-options "--std=c++0x" }
template<typename T, typename U> struct same_type;
template<typename T> struct same_type<T, T> {};
template <typename T>
struct S
{
typedef T const (&type)();
};
void f()
{
// initial implementation didn't ignore const qualifier on
// reference, resulting in a typedef of 'const int& (&)()'
same_type<S<int &>::type, int&(&)()>();
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.