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
android
altivec-types-4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/altivec-types-4.C
497
utf_8
44353ecc66faa31e60f8e0a690173f56
/* { dg-do compile { target powerpc*-*-linux* } } */ /* { dg-require-effective-target ilp32 } */ /* { dg-require-effective-target powerpc_altivec_ok } */ /* { dg-options "-maltivec -mno-vsx -mno-warn-altivec-long" } */ /* These should not get warnings for 32-bit code when the warning is disabled. */ __vector long...
google
android
complit3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/complit3.C
192
utf_8
7c0cfd2335d61954c46222aa7517e055
// { dg-options "" } int Compound_Literals_0() { static int y[] = (int []) {1, 2, 3}; // { dg-error "init" } static int z[] = (int [3]) {1}; // { dg-error "init" } return y[0]+z[0]; }
google
android
stmtexpr3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/stmtexpr3.C
93
utf_8
15be25b1a07f94e4d65103bfb52d6406
// PR c++/16112 // { dg-options "" } struct A { A(); }; A foo() { return ({ A(); }); }
google
android
complit4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/complit4.C
119
utf_8
f2a3354acae823d1855d3f7820f78229
// PR c++/23172 // { dg-do run } // { dg-options "" } int i = (int) {7}; int main () { if (i != 7) return 1; }
google
android
attrib14
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib14.C
356
utf_8
cad6da8a3195139936efb7226304caa3
// PR c++/13170 // The bogus attribute is ignored, but was in TYPE_ATTRIBUTES during // parsing of the class, causing some variants to have it and some not. struct __attribute__((bogus)) A // { dg-warning "ignored" "" } { virtual ~A(); void foo(const A&); void bar(const A&); }; void A::foo(const A&) {} ...
google
android
tmplattr1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/tmplattr1.C
377
utf_8
b0c4b5418bbb0cea1304a888bae68465
// PR c++/24260 // { dg-do compile { target { { i?86-*-* x86_64-*-* } && ia32 } } } #define stdcall __attribute__((stdcall)) struct T { template <class S> static int stdcall func(int arg1, int arg2); }; template <class S> int stdcall T::func(int arg1, int arg2) { return arg1+arg2; } struct dummy {}; void xx(...
google
android
typeof9
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/typeof9.C
312
utf_8
d7e6d10c23ed31b44c2e6c3268ab2b30
// { dg-do compile } // PR c++/14106: ICE with typeof of function template. template<class T> void j (T i) { } template<typename T> void instanciate () { static void (*fp) (T) = j; __typeof__ (j) *p; // { dg-error "unknown|invalid" } } template void instanciate<float>();
google
android
label4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/label4.C
213
utf_8
745640ccb4853caedd76af8799204a4b
// PR c++/20563: ICE (--enable-checking), infinite loop (--disable-checking) // { dg-do compile } __label__ *l; // { dg-error "not at the beginning of" }
google
android
underlying_type9
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/underlying_type9.C
798
utf_8
7156372ea568049610a6b46322d8d564
// { dg-do compile { target c++11 } } template<typename T1, typename T2> struct is_same { static const bool value = false; }; template<typename T> struct is_same<T, T> { static const bool value = true; }; enum E1 : unsigned { }; enum E2 : char { }; enum class E3 { }; enum class E4 : unsigned char { c = 1 }; ...
google
android
typename1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/typename1.C
303
utf_8
a55635b999e217d4900dcb3975178408
// PR c++/6255 // { dg-options "-fpermissive -w" } template <class T> struct A { typedef int X; }; template <class T> struct B { typedef A<T> Y; void f (typename Y::X); }; template <class T, class T1, class T2, class T3> struct C : public B<T> { void g (typename B<T>::Y::X); }; template class B<int>;
google
android
vector10
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector10.C
163
utf_8
57968f25892a26e6c8c805a0122dda46
// PR c++/34914 // { dg-do compile } struct A { int __attribute ((vector_size (8))) x; }; void foo () { __attribute ((vector_size (8))) int A::*p; p == 0; }
google
android
case-range2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/case-range2.C
639
utf_8
c01084c124adab852656539df4dce559
// { dg-do compile } // Tests if case ranges (a GNU extension) correctly emit messages // about overlapping ranges. // { dg-options "" } const int low = -2; const int high = 15; template <typename T> T f2 (T i) { switch (i) { case low ... high : return i + 1; // { dg-error "previously" } case 5 : return ...
google
android
vla3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vla3.C
281
utf_8
f603634b7e2ab93b87e602f38ebcc397
// PR c++/28903 // { dg-options "" } template <class> struct View { int n; }; template <class ViewA> struct ViewDom : View<ViewA> { using View<ViewA>::n; ViewDom(); }; template <class ViewA> ViewDom<ViewA>::ViewDom() { char a[n]; } void element( ) { ViewDom<int> a; }
google
android
is_literal_type1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/is_literal_type1.C
225
utf_8
d97310b12ece2c21881785f78f44e64a
// PR c++/48771 // { dg-do compile { target c++11 } } struct NonLiteral { NonLiteral(); ~NonLiteral(); }; static_assert(__is_literal_type(NonLiteral&), "Error"); static_assert(__is_literal_type(NonLiteral&&), "Error");
google
android
is_class_error1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/is_class_error1.C
118
utf_8
00827fb723064c984bd82e533710599b
// PR c++/33212 template<int> void foo() { __is_class((int); // { dg-error "type-specifier|primary-expression" } }
google
android
tmplattr5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/tmplattr5.C
773
utf_8
0675b180ea1558119008645720d1da58
// PR c++/19407 // { dg-do run } typedef float global_vector_type __attribute__((vector_size(16))); template <class T> struct A { typedef T type; }; template < typename Val > struct S { typedef typename A<Val>::type vector_type __attribute__((vector_size(16))); typedef Val vector_type2 __attribute__((vector_si...
google
android
attrib2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib2.C
169
utf_8
7b769337b45c87f3c5f62ad1dc100502
// Test that an early attribute doesn't confuse uses of a class. // { dg-do compile } struct __attribute__ ((packed)) A { void f () const; }; void A::f () const { }
google
android
vector12
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector12.C
88
utf_8
173dc80ba2834a9afdc07f599ac08c74
// PR c++/34917 // { dg-do compile } const int i __attribute ((vector_size (8))) = {};
google
android
has_virtual_destructor
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/has_virtual_destructor.C
1,364
utf_8
1e97ea87cc47ea2540c97f4f9363bd79
// { dg-do run } #include <cassert> #include <exception> struct A { double a; double b; }; union U { double a; double b; }; struct B { virtual ~B() { } }; struct C : public B { }; struct D { ~D() { } }; template<typename T> bool f() { return __has_virtual_destructor(T); } template<typename T> class...
google
android
va-arg-pack-len-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/va-arg-pack-len-1.C
2,565
utf_8
5767d28306995682901a8025cc09bcf5
// { dg-do run } // { dg-options "-O2" } #include <stdarg.h> extern "C" int error_open_missing_mode (void) __attribute__((__error__ ("open with O_CREAT needs 3 arguments, only 2 were given"))); extern "C" int warn_open_too_many_arguments (void) __attribute__((__warning__ ("open called with more than 3 arguments")...
google
android
forscope1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/forscope1.C
371
utf_8
ddff3d312dcb75275526c22a8eb2891b
// { dg-do compile } // { dg-options -fno-for-scope } // Bug 4206. We were nesting SCOPE_STMTs badly. struct A { A (); ~A (); }; void Go( ) { for (int i = 1;;) { switch (1) { default: {} } A d; } i; }
google
android
has_nothrow_copy-7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/has_nothrow_copy-7.C
172
utf_8
150973854d7c2e7fabaa14d921bdd8d1
// { dg-do run { target c++11 } } #include <cassert> struct S { S (const S&) throw (); S (S&&) throw (int); }; int main () { assert (__has_nothrow_copy (S)); }
google
android
attrib35
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib35.C
504
utf_8
d565544bc9cdd84f0740d250884ccd53
// { dg-do compile { target i?86-*-* x86_64-*-* } } // { dg-options "-O3 -msse2" } // { dg-require-effective-target sse2 } // You can make NON-template typedefs with a large alignment. typedef double AlignedDoubleType __attribute__((aligned(16))); template <typename RealType> RealType f(const RealType* p) { // But ...
google
android
packed6
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/packed6.C
1,293
utf_8
54fc351826d44abec62c9c7f09228d06
// PR c++/15209 // { dg-options "-w" } __extension__ typedef __SIZE_TYPE__ size_t; typedef unsigned char uint8_t; typedef unsigned short int uint16_t; typedef unsigned int uint32_t; __extension__ typedef unsigned long long int uint64_t; typedef uint8_t u8; typedef uint16_t u16; typedef uint32_t u32; typedef uint64_t...
google
android
attr-alias-3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attr-alias-3.C
112
utf_8
69811b8fc2b34f8d08df08a09daf78e1
// PR c++/56134 // { dg-require-alias "" } char a; class Q { static char q __attribute__ ((alias ("a"))); };
google
android
label2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/label2.C
124
utf_8
4f5a16939771bbd392025ca98b00ad61
// { dg-options "" } template <typename T> void f() { l: void *p[] = { &&l }; goto *p[0]; } template void f<int>();
google
android
vector1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector1.C
162
utf_8
1e6ab4b0a8dd095b526fad3f97ec5a91
// PR c++/11895 // This used to ICE in reshape_init. __attribute__((vector_size(16))) int a1 = { 100, 200, 300, 400 };
google
android
utf16-4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf16-4.C
871
utf_8
2fb8e506f14283497eb1922d736535c2
/* Expected errors for char16_t character constants. */ /* { dg-do compile { target c++11 } } */ const static char16_t c0 = u''; /* { dg-error "empty character" } */ const static char16_t c1 = u'ab'; /* { dg-warning "constant too long" } */ const static char16_t c2 = u'\U00064321'; /* { dg-warning "constant too long"...
google
android
asm2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/asm2.C
242
utf_8
80a3695697c7262c931be9b1380fa283
// Bug: in a template, we forgot that this was a simple asm, and decided // that %edi was a malformed operand specifier. template <class T> class I { public: void f() { asm ("# mov %edi, %esi" ); } }; int main () { I<int> x; x.f(); }
google
android
is_polymorphic
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/is_polymorphic.C
1,278
utf_8
27bbb5a6652af10bc63d2ec1a4616b6e
// { dg-do run } #include <cassert> #include <exception> struct A { double a; double b; }; class B { virtual void rotate(int) { } }; class C : public B { }; union U { double a; double b; }; template<typename T> bool f() { return __is_polymorphic(T); } template<typename T> class My { public: b...
google
android
utf-array-short-wchar
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-array-short-wchar.C
1,703
utf_8
60d9840dd4da5a3acbb3fbe0ae2cd345
/* Expected errors for char16_t/char32_t string literals. */ /* { dg-do compile { target c++11 } } */ /* { dg-options "-fshort-wchar" } */ const char s_0[] = "ab"; const char s_1[] = u"ab"; /* { dg-error "from wide string" } */ const char s_2[] = U"ab"; /* { dg-error "from wide string" } */ const char s_3[] = L"ab"; /*...
google
android
interface4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/interface4.C
294
utf_8
99a548af69d71a6aacd6a89ab7dcd013
/* https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=227376 */ /* { dg-do compile } */ /* { dg-options "-g2" } */ /* We used to crash when emitting debug info for type N::A because its context was a namespace, not a function. */ #include "interface4.h" void f ( ) { g ( ); }
google
android
has_nothrow_copy-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/has_nothrow_copy-1.C
1,997
utf_8
3dc9db6cec54556688b76a904376f944
// { dg-do run } #include <cassert> struct A { double a; double b; }; struct B { A a; }; struct C : public A { }; struct D { D(const D&) throw() { } }; struct E { E(const E&) throw(int) { } }; struct E1 { E1(const E1&) throw(int) { throw int(); } }; struct F { F() throw() { } }; struct G { G() throw(int...
google
android
is_base_of_diagnostic
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/is_base_of_diagnostic.C
180
utf_8
3f4855d7a4d4c08ec7d75058a6a0f6c9
class A { }; class B; // { dg-error "forward declaration" } union C { }; union D; void f() { __is_base_of(A, B); // { dg-error "incomplete type" } __is_base_of(C, D); }
google
android
alignof2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/alignof2.C
351
utf_8
0c971bcbaac508ae1054a9ee28a27be8
// PRs 16387 and 16389 // We were treating alignof (sa.a) as alignof (typeof (sa.a)), which is // wrong for some fields. // { dg-do run } extern "C" void abort(); struct A { double a; } sa; struct B { char c; double b; } sb; int main() { if (__alignof (sa) != __alignof (sa.a) || __alignof (sb) != __...
google
android
packed11
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/packed11.C
283
utf_8
9cb80a2f0d2b2720aea9e37828f44d0f
// PR c++/26670 struct nonpod { nonpod(); }; struct nonpod_pack { nonpod n; // { dg-warning "ignoring packed attribute" } } __attribute__ ((packed)); struct nonpod_pack2 { nonpod_pack p; // { dg-warning "ignoring packed attribute" } } __attribute__ ((packed));
google
android
attrib23
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib23.C
622
utf_8
9bfb22dfd815b903874089bf6abde356
// PR c++/28112 // { dg-do compile } int i __attribute__((init_priority(;))); // { dg-error "before" } int j __attribute__((vector_size(;))); // { dg-error "before" } int k __attribute__((visibility(;))); // { dg-error "before" } struct A {} __attribute__((aligned(;))); // { dg-error "...
google
android
sync-3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/sync-3.C
229
utf_8
96d325d0b1cb729ac3fd1b3d32a6b67b
// PR debug/41801 // { dg-do compile } // { dg-options "-O2 -g" } struct T { void foo () volatile { __sync_lock_release (&t); __sync_synchronize (); } bool t; }; int main () { T t = { false }; t.foo (); }
google
android
typedef-init
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/typedef-init.C
1,281
utf_8
c2ab0a5977a08b46134ba61eb8b22222
/* { dg-do compile } */ /* { dg-options "-fpermissive" } // suppress default -pedantic-errors */ /* This code used to be a legitimate, if dubious, extension. However, it's been broken since GCC 3.0 (caused ICE) and we have now removed the extension. See PR c/7353. For cases A and C, C++ issues a warning in...
google
android
stmtexpr2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/stmtexpr2.C
1,225
utf_8
e6bc1a09cf3c9d838c7ad4575c3d8740
// { dg-do run } // { dg-options "" } extern "C" int printf (char const *, ...); extern "C" void abort (); // There are two alternate legal renderings. static unsigned int alt1[] = { 11, 10, 21, 110, 111, 121 }; static unsigned int alt2[] = { 10, 11, 21, 111, 110, 121 }; static unsigned int pointer = 0; static unsig...
google
android
mv6
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/mv6.C
477
utf_8
5fa5e6eec310c2baca6e675f51db6f5b
/* Test to check if member version multiversioning works correctly. */ /* { dg-do run { target i?86-*-* x86_64-*-* } } */ /* { dg-require-ifunc "" } */ /* { dg-options "-march=x86-64" } */ class Foo { public: /* Default version of foo. */ __attribute__ ((target("default"))) int foo () { return 0; } ...
google
android
utf-gnuxx98
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-gnuxx98.C
726
utf_8
89b84e37115e599f4ecc4709d1fe471e
/* Expected errors for char16_t/char32_t in gnu++98. */ /* Ensure u and U prefixes are parsed as separate tokens in gnu++98. */ /* { dg-do compile } */ /* { dg-options "-std=gnu++98" } */ const static char16_t c0 = 'a'; /* { dg-error "not name a type" } */ const static char32_t c1 = 'a'; /* { dg-error "not name a type"...
google
android
builtin-bswap1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin-bswap1.C
245
utf_8
fff9b32833bf9b9b7bbcc10ac630a0d9
// PR c/37743 // { dg-do compile } #if defined(__UINT32_TYPE__) && defined(__INT32_TYPE__) void foo (__UINT32_TYPE__); void foo (__INT32_TYPE__); void bar (__UINT32_TYPE__ x) { foo (__builtin_bswap32 (x)); } #else void bar () { } #endif
google
android
attr-ifunc-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attr-ifunc-1.C
561
utf_8
4cfeaac64b2b6474968c108ee206bc37
/* { dg-do run } */ /* { dg-require-ifunc "" } */ /* { dg-options "-Wno-pmf-conversions" } */ #include <stdio.h> struct Klass { int implementation (); int magic (); static void *resolver (); }; int Klass::implementation (void) { printf ("'ere I am JH\n"); return 0; } void *Klass::resolver (void) { int ...
google
android
has_nothrow_copy_odr
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/has_nothrow_copy_odr.C
220
utf_8
326f3135872905cc190039b1e9eb418b
// PR c++/36870 // { dg-do run } #include <cassert> struct S { S (const S&); }; bool f (); int main () { assert (__has_nothrow_copy (S) == f ()); } S::S (const S&) { } bool f () { return __has_nothrow_copy (S); }
google
android
utf-typedef-cxx98
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-typedef-cxx98.C
257
utf_8
960c6b9ddd1bdea1576c8861d7d63855
/* Ensure that a typedef to char16_t/char32_t is fine in c++98. */ /* { dg-do compile } */ /* { dg-options "-std=c++98" } */ typedef short unsigned int char16_t; typedef unsigned int char32_t;
google
android
timevar2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/timevar2.C
297
utf_8
01c68a4ad6501d5104065731b3cf67c4
// PR c++/57524 // { dg-options "-ftime-report" } // { dg-prune-output "wall" } // { dg-prune-output "times" } // { dg-prune-output "TOTAL" } // { dg-prune-output "checks" } namespace detail { namespace indirect_traits {} using namespace indirect_traits; void fn1() { using namespace detail; } }
google
android
vector8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector8.C
393
utf_8
2eae796d26829372d14224527a39750b
/* { dg-do compile } */ /* { dg-options "" } */ /* Check for application of |, ^, and & on vector types. */ #define vector __attribute__((vector_size(16) )) vector float a; vector int a1; vector float b; vector int b1; int f(void) { a = a | b; /* { dg-error "" } */ a = a & b; /* { dg-error "" } */ a = a ^ b; ...
google
android
label11
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/label11.C
370
utf_8
416b5c7eddab17750318ee4dec3372e4
// PR c++/38725 // { dg-do compile } // { dg-options "" } struct A {}; struct B : virtual A {}; int vi; void *vp; void f1 (int i) { goto *i; } void f2 (B b) { goto *b; // { dg-error "cannot convert" } } template <typename T> void f3 (T i) { goto *i; } void f3a () { f3 (vi); } template <typename T> void f4...
google
android
underlying_type11
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/underlying_type11.C
86
utf_8
32d08b925dba9e7ca38d9ec9643c84fa
// PR c++/51414 __underlying_type(int[1]) i; // { dg-error "int \\\[1\\\]|invalid" }
google
android
mv23
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/mv23.C
247
utf_8
1a95854113fb218ac2615cac21a0b4f7
/* Test case to check if Multiversioning works. */ /* { dg-do run { target i?86-*-* x86_64-*-* } } */ /* { dg-require-ifunc "" } */ /* { dg-require-effective-target static } */ /* { dg-options "-O2 -static -march=x86-64" } */ #include "mv15.C"
google
android
gnu-inline-namespace
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/gnu-inline-namespace.C
391
utf_8
b4a8192e545a20f5b7dea0d9fb8a6f63
/* { dg-do compile } */ /* { dg-options "-O" } */ // such that static functions are optimized out /* { dg-final { scan-assembler "func1" } } */ /* { dg-final { scan-assembler "func2" } } */ /* { dg-final { scan-assembler-not "func3" } } */ /* { dg-final { scan-assembler "func4" } } */ /* { dg-final { scan-assembler-not...
google
android
vla7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vla7.C
280
utf_8
f339c929810ba11885868c48c99722f6
// PR c++/40013 // { dg-options "" } template <class T> struct A { struct B { struct { int fn () { return 0; } } b; }; void test (); }; template <class T> void A <T>::test () { B a; int vla[a.b.fn ()]; } int main () { A <char> a; a.test (); }
google
android
vector3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector3.C
128
utf_8
06e44a4208434952189cfd9cd55ae2d8
/* { dg-do compile } */ /* { dg-options "" } */ // PR c++/28302 int __attribute__((vector_size(8))) x; void foo() { ~x; }
google
android
attr-ifunc-3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attr-ifunc-3.C
645
utf_8
83efbf34de5241ab0549d1572e2ca5f8
/* { dg-do run } */ /* { dg-require-ifunc "" } */ /* { dg-options "-Wno-pmf-conversions" } */ #include <stdio.h> struct Klass { int implementation (); int magic (); static void *resolver (); }; int Klass::implementation (void) { printf ("'ere I am JH\n"); return 0; } void *Klass::resolver (void) { int ...
google
android
dllimport-MI1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/dllimport-MI1.C
1,126
utf_8
1ac40f6207ff06264763ab2431688d02
// { dg-do compile { target i?86-*-cygwin* i?86-*-mingw* x86_64-*-mingw* } } // Test handling of MI thunks in dllimported classes. // To build the dll and client app: // g++ -shared -o MI.dll dllexport-MI1.C // g++ -o MItest.exe dllimport-MI1.C -L. MI.dll #include <stdlib.h> #include "dll-MI1.h" extern DLL_IMPEXP ...
google
android
attrib24
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib24.C
118
utf_8
2f298883fda177e9d00832650a772b69
// PR c++/28387 // { dg-do compile } enum __attribute__((unused)) E; // { dg-error "without previous declaration" }
google
android
uow-2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/uow-2.C
115
utf_8
56fb8e2b89ccd1554be150dc21820262
/* { dg-do compile } */ /* { dg-options "-Wall -fms-extensions" } */ typedef int UOW; struct ABC { UOW UOW; };
google
android
builtin4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin4.C
227
utf_8
36bf81cd8b85ba22d49014263cb3a3e2
// Verify that builtin is used when declared in global namespace // { dg-do compile } // { dg-options "-Wall" } extern "C" int printf(const char*,...); void foo() { printf("%d"); // { dg-warning "expects a matching" } }
google
android
va-arg1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/va-arg1.C
112
utf_8
8c967335139201c2858ad5b7c8f47c5e
// PR c++/33462 struct A {}; void foo() { ++__builtin_va_arg(0, A); // { dg-error "operand type is 'A'" } }
google
android
sync-4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/sync-4.C
3,720
utf_8
de7ee3291cc72891edf5c1f1f496208c
/* { dg-do run { target hppa*-*-hpux* *-*-linux* *-*-gnu* powerpc*-*-darwin* *-*-darwin[912]* } } */ /* { dg-require-effective-target sync_long_long_runtime } */ /* { dg-options "-fexceptions -fnon-call-exceptions -O2" } */ /* Verify that the builtin functions are correctly marked as trapping when using -fnon-call-...
google
android
weak1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/weak1.C
440
utf_8
8c86ea641b4518800fb5154a1a151e06
// Test for #pragma weak where the weak alias symbol isn't declared, // although the symbol it is an alias for is defined in the // translation unit. Bug 7544. // { dg-do compile } // { dg-require-weak "" } // { dg-require-alias "" } // { dg-options "-fno-common" } // { dg-final { scan-assembler "weak\[^ \t\]*\[ \t\]_...
google
android
flexary3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/flexary3.C
151
utf_8
986d09588025e81c934963b5e0416942
// PR c++/54441 // { dg-options "" } struct s { char c[]; }; int main() { struct s s = { .c = 0 }; // { dg-error "initializer" } return 0; }
google
android
align2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/align2.C
251
utf_8
9b72806f0ff8dd6bff6e2ef84f0ce102
// PR c++/10179 struct __attribute((aligned(__alignof(double)))) A { /* empty */ }; struct T : public A { char c; }; template<bool> struct StaticAssert; template<> struct StaticAssert<true> {}; StaticAssert<__alignof(T) == __alignof(double)> d;
google
android
uow-4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/uow-4.C
171
utf_8
e1560d761bf56acc26f3ab91d3231b46
/* { dg-do compile } */ /* { dg-options "-Wall -pedantic" } */ extern "C" { typedef int UOW; /* { dg-error "" } */ struct ABC { UOW UOW; /* { dg-error "" } */ }; }
google
android
vector25
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector25.C
74
utf_8
f006e9fbc60cef8755f4653f8255d665
volatile int i __attribute__((vector_size(8))); void foo() { i += i; }
google
android
attrib16
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib16.C
256
utf_8
1feb907828c5492b83a6bb325e5a8f9c
// { dg-do compile } // Origin: <rguenth at tat dot physik dot uni-tuebingen dot de> // PR c++/10479: use of non dependent expressions in attributes in templates template <int i> struct foo2 { float bar __attribute__((aligned(__alignof__(double)))); };
google
android
pr56790-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/pr56790-1.C
456
utf_8
6ee47122bc21243fae0e9de5c41f1944
/* { dg-do compile } */ /* { dg-options "-O2 -fdump-tree-ccp1" } */ /* { dg-prune-output "changes the ABI" } */ typedef long vec __attribute__ ((vector_size (2 * sizeof (long)))); vec f (void) { vec a = { 5, 7 }; vec b = { 11, 13 }; vec m = { -1, 0 }; return m ? a : b; } /* { dg-final { scan-tree-dump "{ ...
google
android
tmplattr3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/tmplattr3.C
942
utf_8
ff67a3df89d9e5bed9e2259c840fd1c3
// PR c++/17743 template<typename T> struct X { typedef char layout_type[sizeof(T)] __attribute ((aligned(__alignof(double)))); layout_type data; }; template<typename T> struct Y { typedef char layout_type[sizeof(T)] __attribute ((aligned(__alignof(T)))); layout_type data; }; template<typename T> struct ...
google
android
desig5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/desig5.C
72
utf_8
b239fd6089caa55c13edcf0be7c6740c
// PR c++/55951 enum { A }; static const char *a[] = { [A] = "a" };
google
android
packed4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/packed4.C
1,184
utf_8
bcf9b6873e48870b8f6014b5da708cd3
// { dg-do run { target { ! default_packed } } } // { dg-options "-w" } // Packed fields are unsuitable for direct reference binding. struct Unpacked { int i; }; int ConstRef (int const &p, int const *ptr, int v) { if (p != v) return 1; if (&p == ptr) return 2; return 0; } int ConstRef (Unpacked const &p,...
google
android
altivec-5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/altivec-5.C
298
utf_8
355a9e23c60206207713180015d48356
/* { dg-do compile { target powerpc*-*-* } } */ /* { dg-require-effective-target powerpc_altivec_ok } */ /* { dg-options "-maltivec" } */ /* PR c++/14426 */ #include <altivec.h> vector unsigned int splat0u() { return vec_splat_u32(0); } vector int splat0s() { return vec_splat_s32(0); }
google
android
utf-dflt2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-dflt2.C
234
utf_8
1c1fbd739adad2cc015ef4db601b5a90
// In C++0x, the u8 prefix should be parsed as separate tokens. // { dg-do compile } // { dg-options "-std=c++98" } const void *s0 = u8"a"; // { dg-error "was not declared" } #define u8 "a" const void *s1 = u8"a"; int main () {}
google
android
has_trivial_destructor-2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/has_trivial_destructor-2.C
83
utf_8
a24f991beb2c5296f2e8144630b7bb1a
// PR c++/36855 typedef char assert_0 [__has_trivial_destructor (int&) ? 1 : -1];
google
android
anon-struct5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/anon-struct5.C
290
utf_8
a883399d4251a031b0d761ef41a67f52
// PR c++/30302 struct A { struct { static int i; }; // { dg-error "prohibits anonymous structs|an anonymous struct|unnamed class" } void foo() { i; } }; struct B { union { static int i; }; // { dg-error "an anonymous union|member of a union|unnamed class" } void foo() { i; } };
google
android
altivec-13
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/altivec-13.C
1,748
utf_8
8269af4690723c041adba936c4db6226
/* Check that vec_step can be used with const vector types. This test is derived from parts of gcc.dg/vmx/8-02.c from Motorola's AltiVec testsuite. */ /* { dg-do compile { target powerpc*-*-* } } */ /* { dg-require-effective-target powerpc_altivec_ok } */ /* { dg-options "-maltivec" } */ #include <altivec.h>...
google
android
pr34829
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/pr34829.C
318
utf_8
d5eea1e0f08dca8eab2b57d02f7bc73a
// Test for PR c++/34829 // Placement new should be ok for non-aggregate Java types. // { dg-do compile } // { dg-options "" } extern "Java" { typedef __java_byte jbyte; } typedef __SIZE_TYPE__ size_t; void *operator new (size_t, void *m) { return m; } jbyte *f(void *memory) { return new (memory) jbyte; }
google
android
vector7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/vector7.C
254
utf_8
499980717843a208168505a264f263e3
// { dg-options "" } // { dg-do compile } // PR C++/31721 and PR 14217 // the attribute vector_size would change a reference type into a pointer type which was wrong. #define vector __attribute__((__vector_size__(16) )) vector int b; vector int &a = b;
google
android
attrib21
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib21.C
229
utf_8
79dfce253a854fcefcd1eb3bf7e60934
// PR c++/20763 typedef void *voidp; struct S { char a; voidp __attribute__ ((aligned (16))) b; }; struct T { char a; void *__attribute__ ((aligned (16))) b; }; int f[sizeof (struct S) != sizeof (struct T) ? -1 : 1];
google
android
builtin5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin5.C
249
utf_8
d5df191d84dcd12a562ac24a79aa0e8d
// Verify that builtin is used when declared in namespace std // { dg-do compile } // { dg-options "-Wall" } namespace std { extern "C" int printf(const char*,...); } void foo() { std::printf("%d"); // { dg-warning "expects a matching" } }
google
android
stmtexpr6
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/stmtexpr6.C
207
utf_8
d104145185fba3180b02bfff96944804
// { dg-do run } // { dg-options "" } int a[128]; int main() { // Check that array-to-pointer conversion occurs in a // statement-expression. if (sizeof (({ a; })) != sizeof (int *)) return 1; }
google
android
builtin6
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin6.C
300
utf_8
b7c9d67e055f43c68752eb5dee97ef5b
// PR c++/19044 // Verify that alternate asm name for builtin named "foo" also gets // applied to its sibling "__builtin_foo". // { dg-do compile } // { dg-final { scan-assembler "fancy_sin" } } extern "C" double sin(double) __asm("_fancy_sin"); double foo(double x) { return __builtin_sin(x); }
google
android
utf-badconcat
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-badconcat.C
904
utf_8
8489bdb85e5446c128b69c25e8731e24
/* Test unsupported concatenation of char16_t/char32_t* string literals. */ /* { dg-do compile { target c++11 } } */ const void *s0 = u"a" "b"; const void *s1 = "a" u"b"; const void *s2 = u"a" U"b"; /* { dg-error "non-standard concatenation" } */ const void *s3 = U"a" u"b"; /* { dg-error "non-standard concatenation" ...
google
android
desig1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/desig1.C
309
utf_8
739dd1176941bfc4e49f4d7f144da1d3
// { dg-options "" } struct a { int x; }; struct b { int x; int y; }; struct foo { union { struct a a; struct b b; } u; }; int main(void) { struct foo bar = { u: { b: { x: 0, y: 0, }}}; (void)bar; return 0; }
google
android
builtin1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin1.C
281
utf_8
2688425f4bb09561395ab602acbbe5c1
// Test whether alternate 'asm' name is applied correctly to // builtin in global namespace // { dg-do compile } // { dg-options "" } // { dg-final { scan-assembler "fancy_printf" } } extern "C" int printf(const char*, ...) __asm("_fancy_printf"); void foo() { printf("abc"); }
google
android
utf8-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf8-1.C
1,853
utf_8
ca30abc2126fc609901904c3cd652f74
// { dg-do run { target c++11 } } // { dg-require-iconv "ISO-8859-2" } // { dg-options "-fexec-charset=ISO-8859-2" } const char *str1 = "h\u00e1\U0000010Dky "; const char *str2 = "\u010d\u00E1rky\n"; const char *str3 = u8"h\u00e1\U0000010Dky "; const char *str4 = u8"\u010d\u00E1rky\n"; const char *str5 = "h\u00e1\U000...
google
android
has_trivial_destructor-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/has_trivial_destructor-1.C
1,331
utf_8
e08978b76f3cf1a71d470561278cf5c9
// { dg-do run } #include <cassert> struct A { double a; double b; }; union U { double a; double b; }; struct B { ~B() { } }; struct C : public B { }; struct D : public A { }; template<typename T> bool f() { return __has_trivial_destructor(T); } template<typename T> class My { public: bool ...
google
android
typeof7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/typeof7.C
112
utf_8
0217210e867cc6de19f825b9e4b680d3
// PR c++/13635 // { dg-options "" } template<int n> class X {template<class Y> typeof(Y::y) foo();}; X<0> x;
google
android
altivec-types-1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/altivec-types-1.C
4,626
utf_8
1db04504ce004854aaca0a08822acd51
/* { dg-do compile { target powerpc*-*-linux* } } */ /* { dg-require-effective-target powerpc_altivec_ok } */ /* { dg-options "-maltivec -mno-vsx -std=c++98" } */ /* Valid AltiVec vector types should be accepted with no warnings. */ __vector char vc; __vector unsigned char vuc; __vector signed char vsc; __vector __b...
google
android
builtin7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin7.C
223
utf_8
f75543f5ea1a62d2e49f182ac3ff8f36
// PR c++/19628 // Verify that __builtin_constant_p may appear in a constant-expression. // { dg-do run } int main() { switch (3) { case (__builtin_constant_p(7) ? 3 : 8): return 0; default: return 1; } }
google
android
attr-alias-2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attr-alias-2.C
517
utf_8
c21af9dbc94718fc298b5a372185c516
/* { dg-do run } */ /* { dg-require-alias "" } */ #include <typeinfo> struct Klass { int implementation () const; virtual int magic () const; }; int Klass::implementation (void) const { return 0; } int Klass::magic () const __attribute__ ((alias ("_ZNK5Klass14implementationEv"))); int __attribute__ ((noin...
google
android
utf-cvt
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-cvt.C
1,805
utf_8
3edab8d8e139ac7de3fd3eae66bfb5fe
/* Test the char16_t and char32_t promotion rules. */ /* { dg-do compile { target c++11 } } */ /* { dg-options "-Wall -Wconversion -Wsign-conversion -Wsign-promo" } */ extern void f_c (char); extern void fsc (signed char); extern void fuc (unsigned char); extern void f_s (short); extern void fss (signed short); extern ...
google
android
attrib32
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/attrib32.C
556
utf_8
ffa6560e9bf74deea2432205818736ea
// PR c++/35315 typedef union { int i; } U __attribute__((transparent_union)); static void foo(U) {} static void foo(int) {} void bar() { foo(0); } typedef union U1 { int i; } U2 __attribute__((transparent_union)); // { dg-warning "ignored" } static void foo2(U1) {} // { dg-message "previously defined" } static...
google
android
always_inline-5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/always_inline-5.C
428
utf_8
ffdb526972a39c85890c287c92939515
// { dg-do compile } struct f { inline f(void); inline void f1(void); int a; }; inline __attribute__((always_inline)) f::f(void) { a++; } inline __attribute__((always_inline)) void f::f1(void) { a++; } void g(void) { f a, b, c, d; a.f1(); } // f::f() should be inlined even at -O0 // { dg-final { sca...
google
android
packed2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/packed2.C
680
utf_8
de5f86b7a10350b9ce405e101438c412
// PR c++/10091 // Original synopsis // Bug: We were dying because in general, B::a doesn't have enough // alignment for us to take its address. But if the B is C::b, it does // have enough alignment, and we should be able to determine that. // This only failed on STRICT_ALIGNMENT targets (i.e. not i686) // July 20...
google
android
mv22
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/mv22.C
247
utf_8
e7267f3b0ef839e4a2d835556d472a34
/* Test case to check if Multiversioning works. */ /* { dg-do run { target i?86-*-* x86_64-*-* } } */ /* { dg-require-ifunc "" } */ /* { dg-require-effective-target static } */ /* { dg-options "-O2 -static -march=x86-64" } */ #include "mv14.C"
google
android
weak4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/weak4.C
178
utf_8
a90a1ccb44e24f11ce27ee962f1c9c2d
// PR c++/52759 // { dg-do compile } // { dg-require-weak "" } // { dg-options "" } #pragma weak foo template <typename T> struct A { }; template <typename T> void bar (A<T> &);
google
android
builtin-offsetof1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/builtin-offsetof1.C
217
utf_8
e84d64a7fbea15d590f3a2780abeffe4
// PR c++/51413 // { dg-options "-w" } struct A { static void foo(); }; int i = __builtin_offsetof(A, foo[1]); // { dg-error "neither a single identifier nor a sequence of member accesses and array references" }
google
android
utf-cxx98
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/utf-cxx98.C
720
utf_8
a48d76439b8fcf9e146d77edce5ced44
/* Expected errors for char16_t/char32_t in c++98. */ /* Ensure u and U prefixes are parsed as separate tokens in c++98. */ /* { dg-do compile } */ /* { dg-options "-std=c++98" } */ const static char16_t c0 = 'a'; /* { dg-error "not name a type" } */ const static char32_t c1 = 'a'; /* { dg-error "not name a type" } */ ...
google
android
anon-struct1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.dg/ext/anon-struct1.C
1,211
utf_8
5080c1dcd67db52ba793867cc63ba3a3
/* { dg-options "-ansi -pedantic -pedantic-errors" } */ /* In strict ISO C++ mode, we don't recognize the anonymous struct extension or any Microsoft C extensions. */ struct A { char a; }; struct B { struct A; /* forward decl of B::A. */ char b; }; char testB[sizeof(B) == sizeof(A) ? 1 : -1]; struct C { st...