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 | attrib36 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib36.C | 441 | utf_8 | 3a70efd2f6593572ae9fb617a5b327c9 | // PR c++/43031
// { dg-do compile { target { { i?86-*-* x86_64-*-* } && ia32 } } }
class T;
class L { };
class P : public L
{
typedef void (__attribute__((__stdcall__)) T::*F) (L*);
void f(bool aAdd);
};
class T
{
public:
virtual void __attribute__((__stdcall__)) A(L *listener) = 0;
virtual void __attribu... |
google | android | is_enum | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/is_enum.C | 1,058 | utf_8 | 03f82ac5f5b864878fa0ffa4383fa338 | // { dg-do run }
#include <cassert>
struct A
{
double a;
double b;
};
class B
{ };
enum E
{
e0
};
template<typename T>
bool
f()
{ return __is_enum(T); }
template<typename T>
class My
{
public:
bool
f()
{ return !!__is_enum(T); }
};
template<typename T>
class My2
{
public:
... |
google | android | gnu-inline-class-static | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/gnu-inline-class-static.C | 566 | utf_8 | 3b39aa1a4010d4127a39b9443b421c4c | /* { 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 "fu... |
google | android | mv7 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/mv7.C | 269 | utf_8 | 3190e2b81a899b4625c07884047b3106 | // { dg-do compile { target i?86-*-* x86_64-*-* } }
// { dg-options "" }
__attribute__((target ("default")))
void foo (void) // { dg-error "previously defined here" }
{
}
__attribute__((target (128)))
void foo (void) // { dg-error "(not a string|redefinition)" }
{
}
|
google | android | cleanup-11 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/cleanup-11.C | 2,428 | utf_8 | 2bf8b32daf9c23f251208697719631a4 | /* { dg-do run { target hppa*-*-hpux* *-*-linux* powerpc*-*-darwin* *-*-darwin[912]* } } */
/* { dg-options "-fexceptions -fnon-call-exceptions -O2" } */
/* Verify that cleanups work with exception handling through realtime signal
frames on alternate stack. */
#include <unwind.h>
#include <stdlib.h>
#include <sign... |
google | android | asm10 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/asm10.C | 417 | utf_8 | 82e001dc60a8f36b8affdc7210de5b60 | // PR inline-asm/32109
// { dg-do compile }
// { dg-options "-O2" }
struct A { int i[3]; ~A (); };
struct A a;
struct B { struct A c; int i; B (); } b;
B::B ()
{
__asm ("" : : "r" (a)); // { dg-error "impossible constraint|non-memory input" }
__asm ("" : : "r" (b.c)); // { dg-error "impossible constraint|non-memory... |
google | android | attrib37 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib37.C | 200 | utf_8 | d849127808e4deaa150bc4ee81a01d1e | // PR c++/43093
// { dg-do compile { target { { i?86-*-* x86_64-*-* } && ia32 } } }
struct S {
int x;
S(const S &s) {}
};
S __attribute__((__stdcall__)) getS();
void test()
{
S s = getS();
}
|
google | android | packed3 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/packed3.C | 662 | utf_8 | 238ffa2ee564d6bf5c854871d9a259dd | // { dg-do compile }
// Packed fields are unsuitable for direct reference binding.
struct Unpacked { int i; };
void Ref (int &p);
void Ref (Unpacked &p);
struct __attribute__ ((packed)) Packed
{
char c;
int i;
Unpacked u;
};
void Foo (Packed &p)
{
Ref (p.i); // { dg-error "cannot bind packed field" "" { target... |
google | android | tmplattr6 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/tmplattr6.C | 192 | utf_8 | b2cbeefe0b660f19695decd8817dfef1 | // Don't crash on an unknown attribute.
struct foo {
template <class T>
void __attribute__((leafify)) bar() {} // { dg-warning "ignored" }
};
void bar(void)
{
foo f;
f.bar<int>();
}
|
google | android | is_base_of | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/is_base_of.C | 1,696 | utf_8 | f15c22cabbedb731c2f01e04c0fc9309 | // { dg-do run }
#include <cassert>
class A1
{
double a;
double b;
};
class A2
{
double a;
double b;
};
class B
: private A1 { };
class C
: private A1, private A2 { };
union U
{
double a;
double b;
};
template<typename T, typename U>
bool
f()
{ return __is_base_of(T, U); }
template<typena... |
google | android | attrib27 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib27.C | 169 | utf_8 | 7a9cbe898bf9f2d20e888431b91e5c67 | //PR c++/29980
struct A { typedef int X; }; // { dg-message "previous declaration" }
struct __attribute__((unused)) A::X; // { dg-error "typedef-name" }
|
google | android | alignof1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/alignof1.C | 312 | utf_8 | ae6df71fd3bee2754f2c1b710ca23b88 | // { dg-do run }
// Bug PR/7363.
template<typename T>
int my_alignof()
{
return __alignof__ (T);
}
template<typename>
struct X { };
int main()
{
return !my_alignof<X<void> >();
} |
google | android | pr57735 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/pr57735.C | 3,917 | utf_8 | db6ceb60c85d19ebe96df1d062b22334 | /* { dg-do compile { target arm*-*-* } } */
/* { dg-options "-march=armv5te -marm -mtune=xscale -mfloat-abi=soft -O1" } */
typedef unsigned int size_t;
__extension__
typedef long long int int64_t;
namespace WTF {
template<typename T> class RefPtr {
public:
inline T* operator->() const { return m_ptr; }... |
google | android | asm12 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/asm12.C | 255 | utf_8 | e44c9c980378260d4b601d86e9cc1197 | // PR c++/55619
// { dg-do compile }
typedef int V __attribute__ ((vector_size (4 * sizeof (int))));
static const V C = { 0x201, 0, 0, 0 };
static const int D = 0x201;
void
f ()
{
__asm volatile ("" : : "m" (D));
} |
google | android | altivec-11 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/altivec-11.C | 252 | utf_8 | 11e05978299d38b5d2b835ef7303988d | /* Test handling of literal constant for dss operation. */
/* { dg-do compile { target powerpc*-*-* } } */
/* { dg-require-effective-target powerpc_altivec_ok } */
/* { dg-options "-maltivec" } */
#include <altivec.h>
void
foo ()
{
vec_dss (1);
}
|
google | android | typeof11 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/typeof11.C | 249 | utf_8 | 4d1f0cfba2837e6c477d300cc30990c4 | // PR c++/37920
template<typename T> T& ensure_obj(const T&);
template <typename T>
void func2(T& t)
{
typedef __typeof__(ensure_obj(t)) ttt;
struct ttt1
{
ttt1( ttt arg0 ){}
} tttt ( t );
}
int main()
{
double d = 5;
func2(d);
}
|
google | android | tmplattr9 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/tmplattr9.C | 330 | utf_8 | 025a5972f75731b8e82a3214589eeedc | // PR c++/34937, 34962
// { dg-require-weak "" }
// { dg-options "" }
struct A
{
static const int i;
};
template<int> void foo()
{
int x[A::i] __attribute((vector_size(8)));
}
template<int> struct B
{
enum { a, b = a };
void bar(B<b>) __attribute((weak));
};
void f()
{
foo<0>();
B<0> b;
b.bar (B<B<0>:... |
google | android | fixed2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/fixed2.C | 97 | utf_8 | 2dec269695cc75bd9f6561ca76c86464 | // PR c++/35319
// { dg-options "" }
void foo()
{
throw 0r; // { dg-error "not supported" }
}
|
google | android | dllimport1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/dllimport1.C | 561 | utf_8 | 54ffcfc4651d456f2bf3004134e3ea4d | // PR c++/7910
// { dg-do compile { target i?86-*-cygwin* i?86-*-mingw* x86_64-*-mingw* } }
// { dg-options { -Wall -W } }
class __attribute__((dllimport)) Foo
{
public:
virtual void dummy_foo_func(void)
{}
void dummy_foo_fun2();
virtual ~Foo(); // avoid warning
};
void Foo::dummy_foo_fun2() // { dg-... |
google | android | is_abstract | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/is_abstract.C | 1,270 | utf_8 | 313119f0af11c076d28d9802655e555a | // { dg-do run }
#include <cassert>
struct A
{
double a;
double b;
};
union U
{
double a;
double b;
};
class B
{
B();
};
class C
{
virtual void rotate(int) = 0;
};
class D
{
virtual void rotate(int) { }
};
template<typename T>
bool
f()
{ return __is_abstract(T); }
template<typename T>
class My
... |
google | android | has_trivial_assign | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/has_trivial_assign.C | 1,548 | utf_8 | c6f0545bc1364e6c2ba02db17185d224 | // { dg-do run }
#include <cassert>
struct A
{
double a;
double b;
};
union U
{
double a;
double b;
};
struct B
{
B& operator=(const B&) { return *this;}
};
struct C
{
virtual int f() { return 1; }
};
struct D
: public B { };
struct E
: public A { };
struct F
{
A a;
};
struct G
{
B b;
};
template<typen... |
google | android | underlying_type10 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/underlying_type10.C | 627 | utf_8 | a20beeabe8b4f36b3998cd08071f5308 | // { dg-do run }
// { dg-options "-std=c++0x" }
#include <cassert>
enum E1 : unsigned { E1_en = 1 };
enum E2 : char { E2_en = 1 };
enum class E3 { a = -1 };
enum class E4 : unsigned char { c = 1 };
enum class E5 : int { a = -1, b = 1 };
enum class E6 : long { c = __LONG_MAX__ };
template<typename T>
struct underly... |
google | android | dllimport7 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/dllimport7.C | 813 | utf_8 | fb8210a8ae361b2f2903fa711da2a84f | // { dg-do compile { target i?86-*-cygwin* i?86-*-mingw* x86_64-*-mingw* } }
// Report errors on definition of dllimport'd static data member .
struct Baz
{
Baz(int a_ =0) : a(a_) {}
int a;
};
class __declspec(dllimport) Bar
{
public:
enum {one = 1};
static const int two = 2;
static const int ... |
google | android | complex6 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/complex6.C | 130 | utf_8 | 468b75000e57b0b297306048d98bbfcd | // PR c++/46304
// { dg-options "" }
template<class T>
void f()
{
__complex double d = 1.0 + 2.0i;
}
template void f<int>();
|
google | android | altivec-cell-2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/altivec-cell-2.C | 2,503 | utf_8 | ee8876bb4c7e26216a124a7d6118d4ed | /* { dg-do run { target { powerpc*-*-* && vmx_hw } } } */
/* { dg-do compile { target { powerpc*-*-* && { ! vmx_hw } } } } */
/* { dg-require-effective-target powerpc_altivec_ok } */
/* { dg-options "-maltivec" } */
/* Test the vec_extract VMX intrinsics. */
#include <altivec.h>
extern "C" void abort (void);
vector ... |
google | android | attrib8 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib8.C | 237 | utf_8 | 23c4a640241391acec5a1fd2c3fa5f25 | // PR 8656
// { dg-do compile { target { { i?86-*-* x86_64-*-* } && ia32 } } }
extern int * (__attribute__((stdcall)) *fooPtr)( void);
int * __attribute__((stdcall)) myFn01( void) { return 0; }
void snafu( void)
{
fooPtr = myFn01;
}
|
google | android | vla4 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/vla4.C | 336 | utf_8 | 96ef8e77465b89de054095f26955d054 | // PR c++/29318
// { dg-options "" }
#include <typeinfo>
void f(int i) {
try {
int a[i];
throw &a; // { dg-error "variable size" }
} catch (int (*)[i]) { // { dg-error "variable size" }
}
}
int main()
{
int i = 5;
int va[i];
const std::type_info& info(typeid(&va)); // { dg-error "variable size" }... |
google | android | attribute-test-1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attribute-test-1.C | 860 | utf_8 | ca94f9782ff19bc2f53f5f625b6feffe | // { dg-do run }
// { dg-options "" }
// PR c++/13989
extern "C" void abort();
#define vector __attribute__((vector_size(16)))
struct Constants {
inline vector unsigned int deadbeef(void) const {
return (vector unsigned int){0xdeadbeef, 0xabababab, 0x55555555, 0x12345678};
};
};
inline vector unsigned int ... |
google | android | static1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/static1.C | 363 | utf_8 | 0cc2b837a96214f4ba420513a4d610a8 | // PR c++/23699
// { dg-options "" }
template<typename _CharT > class basic_string;
typedef basic_string<char> string;
template<typename _CharT>
struct basic_string
{
static const int npos = -1;
};
template<typename _CharT>
const int basic_string<_CharT>::npos;
extern template class basic_string<char>;
struct A
{
... |
google | android | utf16-3 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/utf16-3.C | 1,295 | utf_8 | 88060cfdc7c006f72fb8b6f665dfbcc8 | /* Test concatenation of char16_t* string literals. */
/* { dg-do run } */
/* { dg-options "-std=c++0x -Wall -Werror" } */
extern "C" void abort (void);
const static char16_t *s0 = u"a" u"b";
const static char16_t *s1 = u"a" "b";
const static char16_t *s2 = "a" u"b";
const static char16_t *s3 = u"a" "\u2029";
const sta... |
google | android | desig6 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/desig6.C | 208 | utf_8 | 35aaa9ad9e1a43c85492e7354c32d65e | // PR c++/57041
// { dg-options "-std=gnu++11" }
template<typename T>
union u {
T a;
char b;
};
template<typename T>
u<T> make_u(T t) {
return { .a = t };
}
int main() {
return make_u<int>(1).a;
}
|
google | android | desig3 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/desig3.C | 368 | utf_8 | 6aa84e0888c3e522be50c83f640eb04f | // PR c++/51229
// { dg-do compile }
// { dg-options "" }
struct A { int i; };
int a[5] = { .foo = 7 };// { dg-error "used in a GNU-style designated initializer for an array" }
int b[] = { .foo = 8 }; // { dg-error "used in a GNU-style designated initializer for an array" }
A c = { [0] = {} }; // { dg-error "used in ... |
google | android | gnu-inline-global | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/gnu-inline-global.C | 1,265 | utf_8 | 3e78535e0258846fa466a40475303131 | /* Test __attribute__((gnu_inline)).
Check that __attribute__((gnu_inline)) has no effect, in the
absence of extern and/or inline.
Check that we don't get out-of-line definitions for extern inline
gnu_inline functions, regardless of declarations or definitions.
Check that such functions can be overrid... |
google | android | oper1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/oper1.C | 449 | utf_8 | 8f3e3432664712c939fe6dea74deb533 | // { dg-do run }
// Make sure the GNU extension of accepting dropping cv-qualifiers for
// the implicit this argument does not kick in when taking the address
// of an object, since this extension would change the meaning of a
// well-defined program.
struct A {
A* operator&() { return 0; }
};
int main ()
{
const A... |
google | android | is_pod | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/is_pod.C | 1,150 | utf_8 | 0c75de786038aaf47f8b0e7b502d064c | // { dg-do run }
// { dg-options "-std=c++0x" }
#include <cassert>
struct A
{
double a;
double b;
};
struct B
{
B() { }
};
struct C
: public A { };
template<typename T>
bool
f()
{ return __is_pod(T); }
template<typename T>
class My
{
public:
bool
f()
{ return !!__is_pod(T); }
};
templat... |
google | android | vector18 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/vector18.C | 252 | utf_8 | 667e87b03c5180c7d73a2802e5fd6cd6 | /* { dg-do compile } */
/* { dg-options "-std=c++11" } */
typedef signed char __attribute__((vector_size(128) )) vec;
template <class A, class B>
auto f (A *a, B b) -> decltype (*a + b);
void f (...) {}
void g (vec *v, long long l)
{
f (v, l);
}
|
google | android | attrib46 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib46.C | 169 | utf_8 | ad40278e44f810062402fc64b141c84f | // PR c++/40821
struct __attribute__((aligned(8)) S1 { int i; }; // { dg-error "expected" }
struct __attribute__( aligned(8) S2 { int i; }; // { dg-error "expected" }
|
google | android | array2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/array2.C | 257 | utf_8 | f1a9da555162b7ed9f63dd442d842c1c | // { dg-do compile }
// Avoid -pedantic-error default
// { dg-options "" }
// PR 19989 - dependent array of size 0 fails to compile.
template<int I> struct A
{
static const int zero = 0;
};
template<int N> struct B
{
int x[A<N>::zero];
};
B<0> b;
|
google | android | interface1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/interface1.C | 161 | utf_8 | 3a16bb49d1e751989bc6c5980e68cc41 | // PR c++/22252
// { dg-do link }
// { dg-additional-sources "interface1a.cc" }
// { dg-options "-fno-inline" }
#pragma implementation
#include "interface1.h"
|
google | android | fnname3 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/fnname3.C | 1,216 | utf_8 | 9e62aa095a73cd8f1f5e3c31669594cd | // Test whether __func__ works for constructors and destructors.
// { dg-do run }
struct uk9i
{
uk9i();
~uk9i();
static const char* fname;
static bool obj_exists;
};
uk9i::uk9i()
{
obj_exists = true;
fname = __func__;
}
uk9i::~uk9i()
{
obj_exists = false;
fname = __func__;
}
const char* uk9i::fname = 0;... |
google | android | attrib29 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib29.C | 353 | utf_8 | f78a1283d2d4da5ad85040e153e6ee99 | // PR c++/33506
// { dg-do compile }
extern int f1 (char *) __attribute__ ((warn_unused_result));
extern int f2 (char *) throw () __attribute__ ((warn_unused_result));
extern int f2 (char *) throw ();
extern int f3 (char *) __attribute__ ((nonnull (1)));
extern int f4 (char *) throw () __attribute__ ((nonnull (1)));
... |
google | android | pr57362 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/pr57362.C | 6,344 | utf_8 | 627009ec0ac71a6fc351693f33db780f | /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
/* { dg-require-ifunc "" } */
__attribute__((target("default")))
int foo(void) { return 1; }
__attribute__((target("128bit-long-double")))
int foo(void) { return 1; }
__attribute__((target("80387")))
int foo(void) { return 1; }
__attribute__((target("96bit-long-d... |
google | android | attr-ifunc-2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attr-ifunc-2.C | 594 | utf_8 | 620342cf7dd87891e3a40fc63c98d22a | /* { 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 | altivec-types-3 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/altivec-types-3.C | 717 | utf_8 | 30a07083e6958ecd6a518b18392c201d | /* { dg-do compile { target powerpc*-*-linux* } } */
/* { dg-require-effective-target powerpc_altivec_ok } */
/* { dg-require-effective-target lp64 } */
/* { dg-options "-maltivec -mno-vsx" } */
/* These should be rejected for 64-bit code. */
__vector long vl; /* { dg-error "invalid for 64" "" } */
__vector unsign... |
google | android | label6 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/label6.C | 69 | utf_8 | ee824ccb1d507856d211f7e019df9eb0 | // PR c++/32108
__label__ L; // { dg-error "not at the beginning" }
|
google | android | desig2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/desig2.C | 569 | utf_8 | a3a3ed9db90b671ac74a4c8ad63238bd | // Test for C99-style designated array initializer
union U
{
long l;
const char *p;
};
__extension__ U u = { .p = "" };
__extension__ int i[4] = { [0] = 1, [1] = 2 };
// Currently, except for unions, the C++ front end only supports
// designators that designate the element that would have been initialized
// an... |
google | android | utf-cxx0x | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/utf-cxx0x.C | 338 | utf_8 | fcea970f9eed217bb14dbbf80a19c539 | /* Test parsing of u and U prefixes when also used as macros. */
/* { dg-do compile } */
/* { dg-options "-std=c++0x" } */
#define u L
#define U L
const unsigned short c2 = u'a';
const unsigned long c3 = U'a';
const void *s0 = u"a";
const void *s1 = U"a";
int main () {} |
google | android | traits1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/traits1.C | 81 | utf_8 | 5c82bcad933c856bb7bc2222cad5ff0f | // PR c++/58504
template<bool = __has_nothrow_assign(void)> struct A {};
A<> a;
|
google | android | cleanup-10 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/cleanup-10.C | 2,407 | utf_8 | e19e28a9f06a40685c797050b1c92de4 | /* { dg-do run { target hppa*-*-hpux* *-*-linux* powerpc*-*-darwin* *-*-darwin[912]* } } */
/* { dg-options "-fexceptions -fnon-call-exceptions -O2" } */
/* Verify that cleanups work with exception handling through signal frames
on alternate stack. */
#include <unwind.h>
#include <stdlib.h>
#include <signal.h>
#in... |
google | android | complit6 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/complit6.C | 138 | utf_8 | 493a8222f8737e0b1e764acebae321f4 | // PR c++/20103
// { dg-options "" }
struct A
{
A(const A&);
};
struct B
{
A a;
};
void foo(B);
void bar(A &x)
{
foo((B){x});
}
|
google | android | asmspecValid | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/asmspecValid.C | 984 | utf_8 | 5ee066fcb4d2f0a4b7244f6dfe4cf04b | // tests that the asm directive is correctly handled for static fields
// in structures and classes. This only applies to C++; such
// directives generate errors in C. Assembler directives for local
// variables should be tested by the C test suite.
//
// { dg-do compile }
struct Foo {
// This should reference a ... |
google | android | typeof2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/typeof2.C | 516 | utf_8 | d4a84aa4c28cc592a1e9f2cc414b0de8 | // Test typeof with __asm redirection
// { dg-do compile }
// { dg-options "-O2" }
extern "C" {
extern int foo1;
extern int foo1 __asm ("bar1");
int foo1 = 1;
extern int foo2 (int);
extern int foo2 (int) __asm ("bar2");
int foo2 (int x)
{
return x;
}
extern int foo3;
extern __typeof (foo3) fo... |
google | android | altivec-15 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/altivec-15.C | 588 | utf_8 | 05aa93a27032c47400c1728d165f6aeb | /* { dg-do compile { target powerpc*-*-* } } */
/* { dg-require-effective-target powerpc_altivec_ok } */
/* { dg-options "-maltivec -mno-vsx" } */
/* This test was added for an internal compiler error. The number and
content of error messages is irrelevant. */
struct SubData
{
inline const Float Clamp(Float ... |
google | android | uow-1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/uow-1.C | 116 | utf_8 | 28679c5e259c2a169fa3381ab32688b9 | /* { dg-do compile } */
/* { dg-options "-Wall" } */
extern "C" {
typedef int UOW;
struct ABC {
UOW UOW;
};
}
|
google | android | fixed1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/fixed1.C | 231 | utf_8 | cfd6fca862458e42100b9df11b48ee9e | // PR c++/35325
// { dg-options "" }
template<int> struct A {};
template<typename> struct B : A<sizeof(0=0r)> {}; // { dg-error "not supported" }
template<typename> struct C : A<sizeof(0=0r)> {}; // { dg-error "not supported" }
|
google | android | stmtexpr13 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/stmtexpr13.C | 135 | utf_8 | a35a509e151456af5b8cfb76d49c85ed | // PR c++/35747
// { dg-do compile }
// { dg-options "" }
void
foo ()
{
({ i; ({ i; }); 0; }); // { dg-error "was not declared" }
}
|
google | android | asm1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/asm1.C | 986 | utf_8 | d377fb4f9ef6d1ed2029c1551ddf7e3b | // Check that the 3.1 named operand syntax can be used in template functions.
struct arg1 {
int value;
static const int info = 99;
};
struct arg2 {
int value;
static const int info = 11;
};
template<int j>
int foo (void)
{
int i;
asm ("# foo on %[third] %[second] %[fourth] %[first]"
: [first] "=r"... |
google | android | inline1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/inline1.C | 765 | utf_8 | f2cf0baaaf489aa15f22210e07d052d1 | // { dg-do compile }
// { dg-options "-O" }
// Make sure inlined non-outlined functions aren't marked weak.
// We'd get a ".weak xyzzy" annotation trigged by the second declaration.
// { dg-final { scan-assembler-not "weak\[^ \t\]*\[ \t\]_?xyzzy" } }
// The next check isn't really part of the actual test, just to make... |
google | android | builtin9 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/builtin9.C | 84 | utf_8 | 9ec34b90151fc823df34413d59729df4 | // PR c++/21619
// { dg-options "" }
int f[__builtin_constant_p(&"Hello"[0])?1:-1];
|
google | android | asm11 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/asm11.C | 862 | utf_8 | 25fbbf0ac13b6baebc40ebabaedfe317 | // PR c/37772
// { dg-do compile }
// { dg-options "" }
void
foo ()
{
int i;
asm (); // { dg-error "expected string-literal before" }
asm (1); // { dg-error "expected string-literal before" }
asm (int); // { dg-error "expected string-literal before" }
asm (: "=r" (i)); // { dg-error "expected stri... |
google | android | typeof4 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/typeof4.C | 264 | utf_8 | bb35b4ce331483ff19b91d62234fac6b | // { dg-do compile }
// { dg-options "" }
// PR c++/9459: typeof in return type of template function
void foo (int) {}
void foo (double) {}
template <typename C>
typeof(foo(1))
bar () { return foo(1); } |
google | android | pretty1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/pretty1.C | 1,396 | utf_8 | ae2794e104309a224e228d70e4cede48 | // PR c++/6794
// Test whether __PRETTY_FUNCTION__ works in templates, functions and
// in initializers at global scope
// { dg-do compile }
// { dg-options "" }
extern "C" void __assert_fail (const char *, const char *,
unsigned int, const char *)
throw() __attribute__((noreturn));
extern "C" void abort (v... |
google | android | label7 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/label7.C | 225 | utf_8 | 895ee2546695c14f3c38c7a1b79fbac1 | // PR c++/32121
// { dg-do compile }
int f (void)
{
a:;
__label__ a; // { dg-error "not at the beginning" }
int b;
__label__ c; // { dg-error "not at the beginning" }
a:; // { dg-error "duplicate label" }
c:;
}
|
google | android | attrib31 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/attrib31.C | 201 | utf_8 | 871bf59c89d9fdf913b212ba40c878a1 | // PR c++/35097
template<int> struct A;
template<> struct A<0>
{
typedef int X __attribute((aligned(4)));
};
template<typename T> void foo(const A<0>::X&, T);
void bar()
{
foo(A<0>::X(), 0);
}
|
google | android | flexary1 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/flexary1.C | 435 | utf_8 | c0dc41d4a72302e0ac9ef29725c83d30 | // { dg-do compile }
// PR c++ 11614
typedef int ary_t[];
struct test
{
ary_t *b;
int (*a)[]; // this is not a flexible array member
};
void test(void)
{
struct test s;
int (*a)[] = 0;
ary_t *b = 0;
a = s.a;
a = s.b;
s.a = a;
s.b = a;
b = s.a;
b = s.b;
s.a = b;
s.b = b;
} |
google | android | flexary2 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/flexary2.C | 98 | utf_8 | df5a32900f0ab827b9e8d0c72822964f | // PR c++/46688
// { dg-options "" }
struct A {
A(int);
};
struct B {
B() {}
A a[];
};
|
google | android | asm4 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/asm4.C | 48 | utf_8 | f8da779ccf232ebdb2dee94530a1bf48 | void f ()
{
__asm__ __volatile__ ("" : : );
}
|
google | android | altivec-9 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/altivec-9.C | 355 | utf_8 | 5bc21f478c5c54165eb98a3afe01f181 | /* Test for AltiVec function vec_ld, passing a pointer to const vector */
/* { dg-do compile { target powerpc*-*-* } } */
/* { dg-require-effective-target powerpc_altivec_ok } */
/* { dg-options "-maltivec" } */
#include <altivec.h>
typedef vector unsigned char vuc_t;
const vuc_t* p;
vector unsigned char test_vec_ld(... |
google | android | label12 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/label12.C | 454 | utf_8 | 0c4dee38ff36603320c2d05c89f20b89 | // PR c++/39028
// { dg-do compile }
void
f ()
{
int i;
for (i = 0; i < 2; i++)
{
__label__ l;
goto l;
l:;
}
while (i++ < 5)
{
__label__ l;
goto l;
l:;
}
do
{
__label__ l;
goto l;
l:;
}
while (i++ < 8);
if (1)
{
__label_... |
google | android | bitfield4 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/bitfield4.C | 409 | utf_8 | 27e7f277d640d9764e58437f0345ad9d | /* { dg-do compile } */
/* { dg-options "" } */
/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
struct t /* { dg-message "note: offset of packed bit-field 't::b' has changed in GCC 4.4" "" { target pcc_bitfield_type_matters } } */
{
char a:4;
char b... |
google | android | int128-4 | .C | toolchain/gcc/gcc-4.8.3/gcc/testsuite/g++.dg/ext/int128-4.C | 530 | utf_8 | c743bc646bb53371d3685325d0ec75ac | // Test for int128 arithmetic conversions.
// { dg-do compile { target int128 } }
// { dg-options "-std=gnu++11" }
template <class T, class U> struct same;
template <class T> struct same<T,T> { };
#define assert_same(T,U) (same<T,U>())
int main()
{
long long ll;
unsigned long long ull;
__int128 i8;
unsigned _... |
google | android | altivec-types-4 | .C | toolchain/gcc/gcc-4.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/gcc/testsuite/g++.dg/ext/underlying_type9.C | 812 | utf_8 | d9022bc46c2023e40b11ef9928c7fe0d | // { dg-do compile }
// { dg-options "-std=c++0x" }
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 ch... |
google | android | typename1 | .C | toolchain/gcc/gcc-4.8.3/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.8.3/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.8.3/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.8.3/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.8.3/gcc/testsuite/g++.dg/ext/is_literal_type1.C | 239 | utf_8 | 3e93e1a5e8fbd599b1b17b46d7e0b98b | // PR c++/48771
// { dg-do compile }
// { dg-options "-std=c++0x" }
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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/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.8.3/gcc/testsuite/g++.dg/ext/has_nothrow_copy-7.C | 186 | utf_8 | e4b05dcd7a97d0cb2b7a6baec073db70 | // { dg-do run }
// { dg-options "-std=c++0x" }
#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.8.3/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.8.3/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 | label2 | .C | toolchain/gcc/gcc-4.8.3/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.8.3/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.8.3/gcc/testsuite/g++.dg/ext/utf16-4.C | 887 | utf_8 | ac5f1f302552d2e9b354d67c0e3a8a40 | /* Expected errors for char16_t character constants. */
/* { dg-do compile } */
/* { dg-options "-std=c++0x" } */
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 "c... |
google | android | asm2 | .C | toolchain/gcc/gcc-4.8.3/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.8.3/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... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.