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
crash22
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash22.C
318
utf_8
7b2c605c6218e8948fecbe9842677c4b
// { dg-do assemble } // GROUPS passed old-abort struct A { void a1(); void a2(); }; struct B { void A::a1(); // this used to die in chainon(), now grokdeclarator should// { dg-error "" } cannot declare.* void A::a2(); // should be fixed by the 930629 change.// { dg-error "" } cannot declare.* };
google
android
dtors1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/dtors1.C
958
utf_8
2f857c17e34da916969e892b4b17fb4b
// { dg-do run } // GROUPS passed destructors // Check that when an object of a derived class is (implicitly) // destructed (on exit from the block in which it is declared) // that the destructor for the base class also gets executed. // // (also check that this execution doesn't seg-fault) extern "C" int printf (con...
google
android
ctors3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/ctors3.C
156
utf_8
c4ac1885be2041f32f4b901e3e8a6128
// { dg-do assemble } // GROUPS passed constructors class A; class B { public: B(); static A sa; }; class A { public: A(int i); }; A B::sa(1);
google
android
crash62
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash62.C
749
utf_8
75b73030bfec1570c06879b52ebb4bb3
// { dg-do assemble } // GROUPS passed old-abort #include <iostream> void fubar(std::ostream* out, const char* s) { (*out) << s << std::endl; return; } int main() { // Declare a ref and a pointer to the same ostream. // std::ostream* out = &std::cerr; std::ostream& die = std::cer...
google
android
copy1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/copy1.C
309
utf_8
be0508b477fafc7e9e9890447151d65a
// { dg-do run } // GROUPS passed copy-ctors extern "C" int printf (const char *, ...); int count = 0; class C { public: C (int) { count++; } operator int () { return 0; } }; int main () { C c1 (1); C c2 (c1); if (count != 1) { printf ("FAIL\n"); return 1; } else printf ("PASS\n"); }
google
android
crash60
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash60.C
219
utf_8
08f4af8421ae9483842f92b9e3925bcb
// { dg-do assemble } // GROUPS passed old-abort class X { public: X (); int f[4]; }; // Note that we mistakenly initialize the array data member as if it // was scalar X::X () : f (0) {}// { dg-error "" } .*
google
android
template17
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template17.C
592
utf_8
ea1706d9d14be41fc2048b33a29cb1b7
// { dg-do assemble } // GROUPS passed templates struct Regex { int i; Regex(char *, int); }; template<class KEY> class NDAMName { public: static const Regex pattern; static unsigned sequence_number; }; const Regex NDAMName<'L'>::pattern("^[Ll](.*)$", 1);// { dg-error "type/value mismatch" "mismatch" } // {...
google
android
operators7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/operators7.C
173
utf_8
fd824291529aa1c6337a009c9f68b953
// { dg-do assemble } // GROUPS passed operators class A { char *p; public: operator const char *() const { return p; } }; int foo(const A &a) { return (a != 0); }
google
android
dtors2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/dtors2.C
1,105
utf_8
11771f1272b718c8cf7cc1d0433af15e
// { dg-do run } // GROUPS passed destructors // Check that virtual destructors work correctly. Specifically, // check that when you destruct an object of a derived class for // which the base class had an explicitly declared virtual destructor // no infinite recursion occurs. // // Bug description: // The generat...
google
android
ambiguity1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/ambiguity1.C
339
utf_8
4e1a8dcde05561af183e1918c506c22c
// { dg-do assemble } // GROUPS passed ambiguity struct A { A (int); }; struct B { B (int); }; void myfunc (const A& t0); // { dg-message "note" } void myfunc (const B& t0); // { dg-message "note" } int main () { myfunc(1); // { dg-error "ambiguous" } // { dg-message "candidate" "candidate note" { tar...
google
android
overload9
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/overload9.C
507
utf_8
84b9a4e7f109c2a0163d7a4e8b124662
// { dg-do assemble } // GROUPS passed overloading class CLogger // { dg-message "candidate" } { public: void operator() (int,const char *) {}; // { dg-message "note" } void operator() (int,const char *, ...) {}; // { dg-message "note" } } Log; class CGLogger : public CLogger // { dg-message "candidate"...
google
android
cvt4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/cvt4.C
380
utf_8
b55c1b74f8a3feaa1feafbc831245fdc
// { dg-do assemble } // GROUPS passed conversions class A {}; template <class TP> class B { A &(*_f) (A &, TP); TP _a; public: B (A &(*f) (A &, TP), TP a) : _f (f), _a (a) {} friend A &operator<< (A &o, const B<TP> &m) { (*m._f) (o, m._a); return o; } }; A &setw (A &, int); B<int> setw (int n) { retur...
google
android
overload8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/overload8.C
276
utf_8
12363e86b7e84131804e82d8811fd126
// { dg-do assemble } // GROUPS passed overloading typedef struct{double re,im;} complex; class Complex{public:double re,im; inline void operator=(Complex&X){re=X.re; im=X.im;}}; void zxcvbnm(int n,...){n=1;} int main(){complex c; Complex C; zxcvbnm(1,c); zxcvbnm(1,C);}
google
android
crash58
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash58.C
143
utf_8
2ea8e7e4ddc11489cf2a94e03e54ed33
// { dg-do assemble } // GROUPS passed old-abort class X { public: void doit(); }; X::::doit()// { dg-error "" } (syntax|parse) error.* { }
google
android
temporary1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/temporary1.C
201
utf_8
d6da73a6e5dbf7c46a8d20958ce49353
// { dg-do assemble } // GROUPS passed temporaries #include <stdio.h> int main () { int a = 2; if (----a == 0) printf ("a = 0\n"); printf ("a = %d\n", a); }
google
android
crash15
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash15.C
313
utf_8
7529342852a16fca993789714b764021
// { dg-do assemble } // GROUPS passed old-abort #include <iostream> class A { public: virtual ~A() {std::cout << "executed ~A()\n";} }; class B : public A { public: virtual ~B() {std::cout << "executed ~B()\n";} }; int main() { std::cout << "starting\n"; B b; b.~A(); std::cout << "done\n"; }
google
android
nest17
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/nest17.C
159
utf_8
6bc8badb7ef6d461cfae233116e71163
// { dg-do assemble } // GROUPS passed nested-classes class T { public: typedef int I; class Y {int y;}; typedef Y Z; }; T::I i; T::Y y; T::Z z;
google
android
operators4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/operators4.C
2,210
utf_8
0078afa77e0c042f64e4960401e2f54d
// { dg-do assemble } // { dg-options "" } // GROUPS passed operators // Check that the & operator, when applied to a global function // or member function returns a proper value as long as the context // in which the result of & is used requires a pointer to a specific // unambigous (function-pointer) type. // // Th...
google
android
static1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/static1.C
144
utf_8
0b5d1af57221388b1b3a700bd348b25a
// { dg-do assemble } // GROUPS passed static class A { public: int a; };// { dg-error "" } .* void foo7 () { A::a = 3; }// { dg-error "" } .*
google
android
explicit1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/explicit1.C
239
utf_8
8fb3d1219e1b6bb6804f440fea6cc972
// { dg-do assemble } // $7.1.2 disallows explicit on anything but declarations of // constructors ... including friends. class foo { public: foo(); }; class bar { public: friend explicit foo::foo(); }; // { dg-error "" } explicit friend
google
android
code-gen1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/code-gen1.C
687
utf_8
723ea3fbd94d850176380c81b9592351
// { dg-do run } // GROUPS passed code-generation // Check that sub-word sized structs/classes are passed correctly // if the struct/class has a constructor (i.e. ANY constructor). extern "C" int printf (const char *, ...); struct base { unsigned int f1 : 8; unsigned int f2 : 8; base (int ii) { } }; base glo...
google
android
crash34
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash34.C
103
utf_8
5871bb0ee6d20847bec083029e90bc58
// { dg-do assemble } // GROUPS passed old-abort operator int () {}// { dg-error "" } .*// ERROR - .*
google
android
operators5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/operators5.C
777
utf_8
a33203c9057b3652878436db19fd035d
// { dg-do run } // GROUPS passed operators // Check that operators may be (directly) recursive. extern "C" int printf (const char *, ...); struct base { int i; }; base base_variable; base operator+ (const base& left, const base& right) { base ret_val; ret_val.i = left.i + right.i; return ret_val; } base op...
google
android
enum10
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/enum10.C
152
utf_8
2082b04653c52e598d8ab0a387abe4bc
// { dg-do assemble } // GROUPS passed enums class Type { public: enum name { A }; }; class A { }; class B: public A { public: B(); };
google
android
enum14
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/enum14.C
109
utf_8
b180e28476416bee81e2f1814451fa2a
// { dg-do assemble } // { dg-options "-fshort-enums" } // GROUPS passed enums enum E { A = 0x80000000 };
google
android
operators1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/operators1.C
234
utf_8
2af972e38ef7cf8be77bddab49ea6e6b
// { dg-do assemble } // GROUPS passed operators struct A { int x; }; int operator()(A x,float y) { // MUST be a member function// { dg-error "" } .* return 1; } int main() { A x; x(1.0); // { dg-error "" } no match for call }
google
android
warnings7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/warnings7.C
258
utf_8
e3214df23f80cd7dc1ae9b6bf1db06c2
// { dg-do assemble } // { dg-options "-O2 -Wall" } // GROUPS passed warnings template<class T> class X { public: void kill(unsigned i) { vec[i].~T(); } T *vec; }; class Y { }; void x() { X<int> x; x.kill(0); X<Y> y; y.kill(0); }
google
android
template2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template2.C
197
utf_8
9722953c39ced970015aa9729e896d56
// { dg-do assemble } // GROUPS passed templates template <class Q> class Conc { public: static int body(); }; template <class Q> int Conc<Q>::body() {return 0;} int main () { Conc<int> s2; }
google
android
arm2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/arm2.C
567
utf_8
03e3c6cc2504c84e79335688e1814a6a
// { dg-do assemble } // GROUPS passed ARM-compliance // ARM 9.4 ``There cannot be a static and a nonstatic member function // with the same name and the same argument types.'' // // The trick is to make sure it's caught with both orders (static, // then normal, and vice-versa. class X { public: int foo(); ...
google
android
prepost2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/prepost2.C
391
utf_8
e5da916c971196876afa37e2f6a5ce8a
// { dg-do assemble } // GROUPS passed initialization class foo { public: operator ++ (); // { dg-error "" } no type or storage class operator ++ (int); // { dg-error "" } no type or storage class operator ++ (char); // illegal// { dg-error "" } .* operator ++ (short); // illegal// { dg-error...
google
android
misc15
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/misc15.C
214
utf_8
9893e6edc662a5622bc8f4c0d8c89dfc
// { dg-do assemble } // GROUPS passed miscellaneous-bugs struct A { int aa; }; struct B : public A { }; struct C : public A { }; struct D : public C, public B { void fun() { C::aa = 10; } };
google
android
ptrmem3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/ptrmem3.C
590
utf_8
93bc75083ebf8ae5a37fd6ac51d10e9a
// { dg-do assemble } // GROUPS passed pointers-to-members template<class T> class TemplA { T t; }; template<class T> class TemplB { public: typedef void (T::*TClassMethod)(); private: /* This line should not crash cuz of the get_decl_list change in this: * cp-tree.c (list_hash_lookup_or_cons): Make...
google
android
template11
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template11.C
702
utf_8
e9b4f6c50db3c9f8f8362d23b59ecb7f
// { dg-do assemble } // GROUPS passed templates template <class Called> class aCallback { public: aCallback(Called& obj, int (Called::*met)()); int callback(); protected: private: // the object to call Called& object; // the method to apply int (Called::*method)(); }; template <class Cal...
google
android
crash43
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash43.C
501
utf_8
ad82278d54e2a257b24e0ae086dd663f
// { dg-do assemble } // { dg-xfail-if "" { sparc64-*-elf } { "*" } { "" } } // { dg-options "-g" } // GROUPS passed old-abort extern "C" { typedef int jmp_buf[12]; } enum Error { NO_ERROR }; class ErrorHandler { ErrorHandler *previous; static ErrorHandler *error_stack; jmp_buf error_buffer; protected: ...
google
android
template1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template1.C
243
utf_8
8ea3f375d9d6dc50b944e77d696584d2
// { dg-do assemble } // GROUPS passed templates // g++-2.2.1: member functions returning a template type template <class T> struct list { }; struct A { list<int> L; list<int> get_list(); }; list<int> A::get_list() { return L; }
google
android
asm-extn1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/asm-extn1.C
346
utf_8
dc09c52e242933d7d8122e9ef75476a1
// { dg-do assemble { target sparc-sun-* } } // { dg-options "-S" } // GROUPS passed asm-extension // This used to crash because c_expand_asm_keyword didn't know what to // do with this. The parser rules were changed to accept an expr, instead // of a stmt. extern void traptable(void); main() { asm("wr %0,%%tbr...
google
android
crash20
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash20.C
218
utf_8
53a2dd1bdf710845adc926626d619e59
// { dg-do assemble } // GROUPS passed old-abort #include <complex> typedef std::complex<double> Complex; Complex ComputeVVself() { Complex temp1; Complex self[3][3]; self[1][2] = 100.0; return self[1][2]; }
google
android
crash50
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash50.C
365
utf_8
2c7f8a7eb2573701d3b0b03c69b5be88
// { dg-do assemble } // GROUPS passed old-abort class B { public: int i; }; int operator & (const B &s) { return ( s.i );} class C { public: C &operator = (const C &x) { return *this; } }; C &(C::*DD)(const C &x) = ...
google
android
scope1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/scope1.C
205
utf_8
c5a732d7f389384df8cd0dd46d74d63b
// { dg-do assemble } // GROUPS passed scoping int f (int i) { if (i) for (int j = i; j; j--) ; return j; // error: j should only be in scope inside the body of `for'// { dg-error "" } .* }
google
android
misc11
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/misc11.C
275
utf_8
b23bbf6b98781ab53190b81124488a9b
// { dg-do assemble } // GROUPS passed miscellaneous // This should not complain about A::f being abstract. struct A { virtual int f() = 0; }; struct B : virtual A { virtual int f() { return 1; } virtual int g() = 0; }; struct C: B { int g() { return 2; } }; C c;
google
android
warnings1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/warnings1.C
214
utf_8
b2f8f2c21840b4f450c2e42ca987cc2e
// { dg-do assemble } // { dg-options "-Wctor-dtor-privacy" } // GROUPS passed warnings // there should be a warning about foo only defining private methods class foo { // { dg-warning "private" } int bar(); };
google
android
alignof
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/alignof.C
313
utf_8
733594e93bfb4299cc0b06179acc3789
// { dg-do assemble } // GROUPS passed extensions struct bar { int bit : 1; }; void foo (int *r, bar t) { // doing alignof on a bit-field should be illegal __alignof__ (t.bit);// { dg-error "" } .* // both of these (a regular ref and an INDIRECT_REF) should work __alignof__ (r); __alignof__ (*r); }
google
android
crash54
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash54.C
139
utf_8
76cab97db1c153ad14cd499c7d483fa7
// { dg-do assemble } // GROUPS passed old-abort int main() { int a[100], **p; p = &a[50];// { dg-error "" } assignment to.* }
google
android
crash68
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash68.C
496
utf_8
1978e1f61a11b5ee6839705fd2b801ae
// { dg-do assemble } // { dg-options "-w -O" } // GROUPS passed old-abort class RWDlist { public: RWDlist& operator=(const RWDlist&); }; class DataItemRWGDlist : public RWDlist {}; class Base {}; class DataItemList : public Base { private: DataItemRWGDlist m_diList; }; class StatementGroup { public:...
google
android
template13
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template13.C
181
utf_8
1171c643ccd2fe8a7f97229931b07791
// { dg-do assemble } // GROUPS passed templates template<class T> class ListS { public: class Vix { public: Vix(); }; }; template<class T> ListS<T>::Vix::Vix() { }
google
android
crash67
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash67.C
105
utf_8
ceface3afb873c88388917e015eb9333
// { dg-do assemble } // GROUPS passed old-abort
google
android
parse3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/parse3.C
527
utf_8
9d0d21502ad4ff12ec56a2ec6af54d6a
// { dg-do assemble } // these are marked as expected errors because they evidence an // ambiguity in the grammar between expressions and declarations. // when the parser's been cleaned up or rewritten, these two error // markers can go away, since they'll no longer occur. // Fixed. PR 8545, 2001 01 23 class A { p...
google
android
init4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/init4.C
181
utf_8
a04f0fc12cd92adfb1a94be64e1bfc12
// { dg-do assemble } // GROUPS passed initialization struct CharList { int i; }; const CharList& terminals = { 1 }; // { dg-error "initializer lists" "" { target { ! c++11 } } }
google
android
friend3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/friend3.C
378
utf_8
80dfa47751addc3c9d577d2158ef6696
// { dg-do assemble } // GROUPS passed friends class B { friend class A; enum { bEnum = 1, // { dg-error "comma at end" "" { target { ! c++11 } } } }; int bArray[ bEnum ]; public: void bFunction(int arg[ bEnum ]); }; class A { int aMember; public: void aFunction(int a[B::bEnum]) { ...
google
android
sizeof4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/sizeof4.C
221
utf_8
155582fcdd8e972166db70e5fa5f3f72
// { dg-do assemble } // { dg-options "-pedantic-errors" } // GROUPS passed sizeof // ARM $5.3.2 int main() { // sizeof may not be applied to the type void int l = sizeof (void);// { dg-error "" } .* return 0; }
google
android
cvt1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/cvt1.C
1,049
utf_8
907c310b4820c37a529248243bf29d51
// { dg-do assemble } // GROUPS passed conversions #include <iostream> class Thing { public: typedef enum { GOOD_THING, BAD_THING, } ThingType ; // { dg-error "" "comma" { target { ! c++11 } } } Thing (ThingType type) : thingType (type) { } ~Thing () { } private: ThingType thingType ; } ; class Group { publ...
google
android
template21
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template21.C
447
utf_8
f78d5b5e19be653b3f6b40aa6e8df5a0
// { dg-do assemble } // GROUPS passed templates template<class T> class L { public: L(); T x[30]; int doit(int i) const; }; #ifdef BUG template<class T> int L<T>::doit(int i) const { return x[i].z; } #endif class X { public: class Y { public: Y(); Y(int); int z; ...
google
android
nest23
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/nest23.C
174
utf_8
fba04cbf985f18cbd964bbcbd904749d
// { dg-do assemble } // GROUPS passed nested-classes class CS { public: class PS { }; }; class NCS: public CS { public: class S: public PS { }; }; int i;
google
android
crash4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash4.C
101
utf_8
549525d98ff3703d364f494aff337190
// { dg-do assemble } // GROUPS passed old-abort typedef struct Thing { Thing(); int x; } Thing;
google
android
union1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/union1.C
499
utf_8
fb73bfcd654e33756959a215f2abe65d
// { dg-do run } // GROUPS passed unions // This is fixed by finish_anon_union doing a string_cst_equal check on // the DECL_SIZE of the decls, instead of comparing the DECL_SIZE nodes. // The compiler currently fails to allocate space for the static union. unsigned hash(const double d) { stat...
google
android
crash10
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash10.C
400
utf_8
9bb5650319b1cbd73f548bcbcadbf2b4
// { dg-do assemble } // GROUPS passed old-abort class word { unsigned char b1, b2; public: word (unsigned int i = 0) { b1 = i & 0xff; b2 = (i & 0xff00) >> 8; } operator unsigned int () { return (b2 << 8) + b1; } }; class just_another { int foo; char bar[23]; }; int mumble(word w) { just_another *jap; ...
google
android
init3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/init3.C
680
utf_8
f2652f181d69d7a6744ebc38c4ae83ed
// { dg-do run } // GROUPS passed initialization // p2766: Make sure that members are initialized in order of declaration // in the class, not in order of specification in the mem-initializer list. extern "C" int printf (const char *, ...); extern "C" void exit (int); int count = 0; void die () { printf ("FAIL\n");...
google
android
template4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template4.C
257
utf_8
964c5b3a3aa7a3fef9f1c33793599526
// { dg-do assemble } // GROUPS passed templates // This used to be a circularity in chainon. template <class ARG> struct TMPL { typedef int ARG::*ARG_data_member_ptr; typedef void (ARG::*ARG_func_member_ptr) (); }; struct S { }; TMPL<S> object;
google
android
copy8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/copy8.C
1,614
utf_8
330313d34e8179459b8d6fdbca0b4371
// { dg-do run } // GROUPS passed copy-ctors /* This report is for GCC 2.3.3 running on a Sun/4. The bug is that when a class instance is passed-by-value, GCC does not correctly copy the value. At the end of this report is an example program that demonstrates the bug. It should print: construct A('x') copy A('x'...
google
android
new-array
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/new-array.C
271
utf_8
ce18ed55b4cb7e1075e495fefce8d00f
// { dg-do assemble } // GROUPS passed operator-new typedef struct { int a; } AStruct; void MakeBug() { AStruct *job; // This used to crash, it should now give error(s). job = new AStruct[];// { dg-error "" } .* job = new AStruct; } int main () { MakeBug(); }
google
android
scope2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/scope2.C
368
utf_8
a9d5e4eb3d5a79edcae73706ea6bcbdc
// { dg-do assemble } // GROUPS passed scoping class A { public: A() {} ~A() {} virtual void f() {} }; class B : public A { public: B() {} ~B() {} virtual void f() {} }; B GLOBAL_B; B& foo() {return GLOBAL_B;} int main() { // build_scoped_method_call and build_scoped_ref should know how // to de...
google
android
crash66
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash66.C
2,863
utf_8
2000fd7ff28385cbab610558a172e452
// { dg-do assemble } // { dg-options "-O" } // GROUPS passed old-abort typedef unsigned char uchar; typedef unsigned short ushort; typedef unsigned long ulong; extern int swap_endian; inline ushort swapshort(ushort value) { value &= 0xffff; return ((value << 8) | (value >> 8)); } struct eshort { ushor...
google
android
misc8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/misc8.C
225
utf_8
afb78a982f7ea702909578ace0b9e51a
// { dg-do assemble } // GROUPS passed miscellaneous // used to say invalid lvalue in `&\' class foo { int a; public: foo(int a); }; foo::foo(int a) { foo::a=a; } int main() { foo obj(4); }
google
android
template30
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/template30.C
427
utf_8
7168d5a5ef2d632863cc9e00648acbc5
// { dg-do assemble } // GROUPS passed templates template<class K, class V> class MapLS { }; class String {}; class X1 { }; class RefProto { }; template<class REP> class Ref { }; template <> class MapLS<String, Ref<X1> >: public MapLS<String, RefProto> ...
google
android
label2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/label2.C
147
utf_8
0499329a576a28129c8caa17805883f3
// { dg-do assemble } // GROUPS passed labels extern "C" void abort(); class X { public: X(); }; void foo () { X: ::abort(); goto X; }
google
android
code-gen3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/code-gen3.C
604
utf_8
aecb2d4389f93ab36432fb4257d46f94
// { dg-do run } // GROUPS passed code-generation // Check that passing things which are not a multiple of // 4 bytes in size doesn't mess up other subsequent parameters. extern "C" int printf (const char *, ...); struct base { int f1 : 8; int f2 : 8; }; base global_base; int val1; int test2 (struct base forma...
google
android
warnings8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/warnings8.C
129
utf_8
93cc067d918fc872a51c4f9a4b3e5d3d
// { dg-do assemble } // { dg-options "-Wall" } // GROUPS passed warnings bool foo(unsigned char c) { return (c & 17) != 0; }
google
android
parse6
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/parse6.C
76
utf_8
b43936b6abd4d40567c033f09683b3bb
// { dg-do assemble } class A { }; int main() { A a = a; A b(b); }
google
android
visibility4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/visibility4.C
257
utf_8
715aa94186b2b202e2e9a4997d26444f
// { dg-do assemble } // GROUPS passed visibility template <class T> class Feld { public: Feld(const Feld&) {} }; class Polynom : private Feld<double> { Polynom(); friend Polynom f(const Polynom&); }; Polynom f(const Polynom& p) { return p; }
google
android
init2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/init2.C
249
utf_8
a7d97e82f3eb82db336f6f66c5226612
// { dg-do assemble } // GROUPS passed initialization // this should give an error in require_required_type about not // being allowed to have an initializer list in an argument list. int f(int a = {1});// { dg-error "" "" { target { ! c++11 } } }
google
android
enum8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/enum8.C
298
utf_8
91a419fc7d4cdfc90a1f506dac5b00c9
// { dg-do assemble } // GROUPS passed enums class foo1 { public: enum foo1_enum { ENUM1, ENUM2, // { dg-error "comma at end" "" { target { ! c++11 } } } }; }; class foo2 { private: enum foo1::foo1_enum Enum; }; class foo3 { private: foo1::foo1_enum Enum; };
google
android
copy5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/copy5.C
1,495
utf_8
a9b230fa3f6f281be0b5d7c1b0744eeb
// { dg-do run } // GROUPS passed copy-ctors /* bad: sibelius402> a.out a=5 a.virtMember()=30 BaseClass::Increm --> {i=5, virtMember()=30} a=7 a.virtMember()=30 b=7 b.virtMember()=30 BaseClass::Increm --> {i=7, virtMember()=999} b=9 b.virtMember()=30 sibelius403> good: sibelius406> a.out a=5 a.virtMember()=30...
google
android
crash57
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash57.C
158
utf_8
f99628dfc0766d237ee572c05c96f5ef
// { dg-do assemble } // GROUPS passed old-abort class foo { private: char buffer[1024]; public: foo(); }; int main() { static foo& a = *(new foo); }
google
android
init12
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/init12.C
142
utf_8
62115c076d63c13cb74234ef6b624704
// { dg-do assemble } // GROUPS passed array-bindings char * bob(); int main() { char a[1][2]; a[0] = bob();// { dg-error "" } .* }
google
android
overload10
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/overload10.C
559
utf_8
2ec9f8f263e22d591e448662a3e509f1
// { dg-do assemble } // GROUPS passed overloading class Bed { public: static void bed_func( int (*f)(int &, int, int)); }; class g_func { public: static int save_status; // in compute_harshness, we should be using comptypes, not ==, to // check if this is equivalent to the previous decl; the on...
google
android
overload6
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/overload6.C
342
utf_8
5b6359b5a39b8cb125e95a28558f215b
// { dg-do assemble } // GROUPS passed overloading struct temp_string { temp_string (const unsigned char); }; class String { public: String& operator = (temp_string); String& operator = (const String&); }; class S { public: operator temp_string & () const; }; S lbuf; static void e_r () { String a; ...
google
android
crash12
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash12.C
145
utf_8
c487c2f1d306c4b5ffd996ab598aac07
// { dg-do assemble } // GROUPS passed old-abort class X { int i; public: X(int j); } X *x = new X[10]();// { dg-error "" } .*
google
android
copy4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/copy4.C
843
utf_8
e735bca9c3e4a1f2da89ae49ee4a166d
// { dg-do run } // GROUPS passed copy-ctors // Using Cfront 3.0.1 the programm below prints // // A() // A(const A& a) // ~A() // A(A& a) <---- !!! // ~A() // ~A() // // the g++ 2.2.2 (sparc-sun-sunos4.1) generated code prints // // A() // A(const A& a) // ~A() // A(const A& a)...
google
android
ptrmem4
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/ptrmem4.C
317
utf_8
b8d1e42f311d8afc82fcf4dbfd490613
// { dg-do assemble } // GROUPS passed pointers-to-members class X { private: int i; public: X(int k) { i=k; } int operator=(X &a) { return i = a.i; } int operator=(int ii) { return i = ii; } }; int main(void) { int (X::*op1_ptr)(X&); op1_ptr = &X::operator=; // g++ gives error return 0; }
google
android
cvt3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/cvt3.C
1,274
utf_8
1971e0805b89163d89927364e33cd9ec
// { dg-do assemble } // GROUPS passed conversions class GttObject {}; class GctObject: virtual public GttObject {}; class NDAMObject: virtual public GttObject, virtual public GctObject {}; class GctHashObject: virtual public GctObject {}; class GctRef: virtual public GctHashObject { public: operator void*() const; }...
google
android
crash55
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash55.C
296
utf_8
b393361bcb07d81f8fe0ac5bb8839dd2
// { dg-do compile } // GROUPS passed old-abort extern int f(int); // { dg-message "old declaration" } int& f(int x) // { dg-error "new declaration" } { int local; // { dg-warning "reference to local" } local = x+2; return local; }
google
android
crash7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash7.C
1,027
utf_8
dad3cd990eeef0bc5b2a157565620d3b
// { dg-do assemble } // GROUPS passed templates template<class T> class Vector { int sz; T *v; public: Vector (int s) : sz (s) { v = new T[sz]; } ~Vector () { delete[] v; } T &operator[] (int i) { return v[i]; } int size () { return sz; } }; template<class T>// { dg-error "" } previous definition of T s...
google
android
enum13
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/enum13.C
191
utf_8
3ea57e60fd8bc5fc0eb4dcd8ebb05a7b
// { dg-do assemble } // GROUPS passed enums enum COLOR { red, green, blue }; struct S { COLOR color:2; }; COLOR color; S object; void fubar () { color = object.color; }
google
android
crash32
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash32.C
140
utf_8
89408b609531415622dd2a89bcc6cf45
// { dg-do assemble } // { dg-options "-fshort-enums" } // GROUPS passed old-abort enum Bool { FALSE, TRUE }; Bool foo () { return TRUE; }
google
android
mutable1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/mutable1.C
103
utf_8
5d2329af0ff02e79f3f79c0b57005d11
// { dg-do assemble } // GROUPS passed mutable class foo; class bar { mutable foo const *foobar; };
google
android
enum1
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/enum1.C
200
utf_8
f4a6198b346287ed8325efbed8566b1d
// { dg-do assemble } // GROUPS passed enums class foo { public: enum bar { baz = 1, bat = 7 }; }; class derv : public foo { }; int main() { foo::bar x = foo::baz; derv::bar y = derv::bat; }
google
android
dtors3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/dtors3.C
1,253
utf_8
e2a9f30a7ba6f25639381c312b380c4d
// { dg-do run } // GROUPS passed destructors // Check that member and base classes get properly destructed // when an object of a derived class is destructed via a pointer // to it which only has a "compile-time" type of "pointer-to-base". // // Note that in order for this test to work properly, the destructor // for...
google
android
enum12
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/enum12.C
180
utf_8
6e6712bb465842808e9709b41ad09c15
// { dg-do assemble } // GROUPS passed enums enum Bool { False, True }; enum Bool object; struct S { Bool field:1; void copy_enum_bit_field () const { object = field; } };
google
android
crash40
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash40.C
225
utf_8
3b168f8ca606522149df9bdb8d936a0e
// { dg-do assemble } // GROUPS passed old-abort class foo { public: virtual foo &operator <<(foo &(foo::*)(foo &)); }; foo &foo::operator<<(foo &(foo::*manip)(foo &)) { (this->*manip)(*this); return *this; }
google
android
prepost3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/prepost3.C
172
utf_8
f8dd4c752216e799de3b9b80e065b0af
// { dg-do assemble } // GROUPS passed prefix-postfix class Y { public: friend Y operator++ (Y&); friend Y operator++ (Y&, char); // illegal// { dg-error "" } .* };
google
android
nest3
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/nest3.C
174
utf_8
14f506167b89a107040db6b421bd9be1
// { dg-do assemble } // GROUPS passed nested-classes class X { public: struct M2 { int m; }; M2 g(int); }; X::M2 X::g(int i) { X::M2 m2; return m2; } int main() { }
google
android
nest10
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/nest10.C
273
utf_8
e6320d64763b67bdb98cab5b655bf5ca
// { dg-do assemble } // GROUPS passed nested-classes class A { public: class B { public: int f (); void g (int); private: int b; }; }; int A::B::f () { int val=b; return val; } void A::B::g (int val) { b = val; } int main () { }
google
android
crash52
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/crash52.C
295
utf_8
e1871547e771dae40fb84cc4ec409e44
// { dg-do assemble } // { dg-options "-Wreturn-type" } // GROUPS passed old-abort #include <iostream> class A { public: friend A f(A &a);// { dg-message "old declaration" } }; A &f(A &a) {// { dg-error "new declaration" } std::cout << "Blah\n"; } // { dg-warning "no return statement" }
google
android
misc7
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/misc7.C
289
utf_8
72481e2213bd97540343ed3471a45495
// { dg-do run } // GROUPS passed miscellaneous extern "C" int printf (const char *, ...); int main() { int i = 0; // Make sure build_unary_op correctly computes this. int *pi = &(++i); *pi = 4; if (i != 4) { printf ("FAIL\n"); return 1; } else printf ("PASS\n"); }
google
android
operators8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/operators8.C
130
utf_8
412200ab340af309b05a21dd952707ea
// { dg-do assemble } // GROUPS passed operators struct A { char *p; operator char *(); }; char foo(A a) { return a[0]; }
google
android
err-msg8
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/err-msg8.C
145
utf_8
a14ce5b47e835ce3d50a055484c37e9a
// { dg-do assemble } // GROUPS passed error-messages operator int ; int j; // { dg-error "" } declaration of `operator int' as non-function.*
google
android
nest2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/nest2.C
195
utf_8
a19881ab8fa85bcc5df938e0dbfdd9f4
// { dg-do assemble } // GROUPS passed nested-classes class A { protected: class B { public: ~B(); private: float _datum; }; private: B *_b; }; A::B::~B() { _datum = 8.0; }
google
android
err-msg5
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/err-msg5.C
138
utf_8
905514d94e69c283791a395b1caa8949
// { dg-do assemble } // GROUPS passed error-messages class foo {}; ~foo () {}// { dg-error "" } destructors must be member functions.*
google
android
sizeof2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/sizeof2.C
273
utf_8
232bbc492ea7277970b768de8806f2c0
// { dg-do assemble } // { dg-options "-pedantic-errors" } // GROUPS passed sizeof // ARM $5.3.2 void f() { } struct foo { int bit : 1; }; int main() { // sizeof may not be applied to a bit-field foo f; int i = sizeof (f.bit);// { dg-error "" } .* return 0; }
google
android
misc2
.C
toolchain/gcc/gcc-4.9/gcc/testsuite/g++.old-deja/g++.brendan/misc2.C
443
utf_8
17c9323951efbf191223de7c11466ff8
// { dg-do assemble } // GROUPS passed miscellaneous-bugs // Should be fixed by: // // * cp-decl.c (grokvardecl): Don't complain about duplicate // definitions of `extern "C"' declarations (parallelize it with how // regular `extern' decls are handled). extern "C" double _MaXdOuB, _MiNdOuB; extern "C" double _MaXdOu...