plateform stringclasses 1
value | repo_name stringclasses 2
values | name stringlengths 1 78 | ext stringclasses 2
values | path stringlengths 15 1.11k | size int64 1 8.55M | source_encoding stringclasses 11
values | md5 stringlengths 32 32 | text stringlengths 0 8.49M |
|---|---|---|---|---|---|---|---|---|
google | chromium | using3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/using3.C | 178 | utf_8 | c9b550ead8867586800cdeee63308c31 | class A
{
public:
typedef int T;
int a;
};
class B : virtual private A
{
};
class C : virtual private A, public B
{
public:
using A::a;
using A::T;
};
C::T x;
|
google | chromium | covariant9 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant9.C | 492 | utf_8 | 0511cb5b77e0c5f25eb7db8a8b1daba4 | // { dg-do link }
// { dg-options "-w -ansi -pedantic" }
// PR c++/12698. Duplicate covariant thunks emitted.
struct c1 {};
struct c0 {
int i;
virtual c1& f10() {}
};
struct c2 : virtual c1, c0 { };
struct c6 : virtual c2, c0 {
virtual c2& f10() {}
};
struct c14 : virtual c2 { };
struct c19 : virtual ::c6 {
vir... |
google | chromium | null1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/null1.C | 257 | utf_8 | 929bd841afc583f6793a33214c34c08a | // PR c++/5453: Test that we don't assume that the pointer target of a
// reference is non-null just because we know the reference isn't.
// { dg-do run }
struct V { };
struct A: virtual public V { };
A* ap;
A*& apr (ap);
int main ()
{
V* vp = apr;
}
|
google | chromium | covariant15 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant15.C | 295 | utf_8 | 764a60120a5dcf46b78223dc70cad2dd | /* This used to ICE (PR c++/27492) */
/* { dg-do "compile" } */
struct A {};
class B : A
{
virtual A* foo(); /* { dg-error "overriding" } */
};
struct C : virtual B
{
virtual C* foo(); /* { dg-error "invalid covariant return type" } */
};
C* C::foo() { return 0; }
struct D : C {};
|
google | chromium | access1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/access1.C | 252 | utf_8 | 176e66df5d6aa9dd76c8fe406b78a370 | // Test that we can access a member from an inaccessible base if it has
// been promoted with a using-declaration.
// { dg-do compile }
struct A
{
int i;
};
struct B: private A
{
using A::i;
};
struct C: public B
{
void f () { B::i = 0; }
};
|
google | chromium | using2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/using2.C | 488 | utf_8 | 26f51eac0b25566825aafb23697d10a4 | // { dg-do run }
// PR 7919. Methods found via using decls didn't have their this
// pointers converted to the final base type.
struct Base {
int m;
protected:
void *Return () { return this; }
};
struct Derived : Base {
using Base::Return;
virtual ~Derived () {}
};
int main ()
{
Derived d;
return stati... |
google | chromium | virtual4 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/virtual4.C | 335 | utf_8 | b7f032736331f1ff851d46fe5aef118a | // PR c++/31027
struct A {};
template<typename T>
struct C: virtual A {
C() {}
template<typename T_OTHER> C(const C<T_OTHER>&) {}
C func(const class C<long>&) const;
operator bool() const;
};
template<typename T>
struct D: C<T> {
void func2() {
C<int>a;
a.func(a);
}
};
void func3() {
C<int>a;
... |
google | chromium | covariant11 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant11.C | 453 | utf_8 | ca45ea7dee32a2ef2bfe9224172afb59 | // { dg-do compile }
// PR c++/12700 ICE with covariancy
struct c2 { int i; };
struct c1 {
virtual c2& f8() {}
};
struct c3 : c1, c2 {
virtual c2& f8() {}
};
struct c11 : public c1 {
virtual c3& f8() {}
};
struct c15 : virtual c3 {
virtual c2& f8() {}
};
struct c18 : virtual c11 {
virtual c15& f8();
};
c15& c... |
google | chromium | covariant6 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant6.C | 330 | utf_8 | c5a6312f5be1ce7f30501a4b629453f3 | // { dg-do compile }
// We ICE'd
struct c0 {};
struct c1 : virtual c0
{
virtual c0 &f2();
};
struct c3 : virtual c1
{
virtual c1 &f2();
};
c1 &c3::f2()
{
throw 0;
}
struct c4 : virtual c3
{
}; |
google | chromium | operator2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/operator2.C | 451 | utf_8 | 8ec3eec10bb6beeb5a1ec171d1b02302 | typedef int INT_TYPEDEF;
template<class T>
class TypedIfc
{
public:
virtual ~TypedIfc() { }
virtual operator const T&() const = 0;
virtual const T& operator= (const T& t) = 0;
};
template<class Tnative>
class NullIfc : public TypedIfc<Tnative>
{
public:
const Tnative& operator= (const Tnative& t) { return t; ... |
google | chromium | virtual1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/virtual1.C | 275 | utf_8 | 5d675d5e8dcd9e6e6286c004b1e515ee | //PR c++/27952
struct A
{
virtual ~A() {}
};
struct B : A, virtual A {}; // { dg-error "duplicate base|forward declaration" }
struct C : A, B {}; // { dg-error "duplicate base|invalid use" }
C c; // { dg-error "aggregate" }
|
google | chromium | union1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/union1.C | 98 | utf_8 | 8ac7470626f12e0cdefa40e25583472b | // PR c++/15507
struct A {
// empty
};
struct B : A {
int b;
};
union U {
A a;
B b;
};
|
google | chromium | covariant13 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant13.C | 443 | utf_8 | a30e748e839e3234af2982a8507640f3 | // PR 21427: ICE on valid
struct B1 {
public:
virtual void foo();
};
struct B2 {
public:
virtual B2 & bar() = 0;
};
struct I : public B1, B2 {
public:
virtual ~I();
virtual I & bar();
};
struct D : public I {
virtual ~D();
}; |
google | chromium | covariant10 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant10.C | 369 | utf_8 | cddfdb8e9f01440bf52ef339bab825d0 | // { dg-do compile }
// PR c++/12699 ICE with covariancy
struct c1 {
virtual void f1() const {}
};
struct c5 {};
struct c6 : virtual c1 {
virtual c5* f33() const {}
};
struct c13 : virtual c5 { };
struct c17 : virtual c6
{
virtual c13* f33() const {}
}; |
google | chromium | covariant5 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant5.C | 322 | utf_8 | 93a19aa63029d81a5f4f59b8b81d11a8 | // { dg-do compile }
// We ICE'd
struct c0 {};
struct c1 : virtual c0
{
virtual c0 &f2();
};
struct c3 : c1
{
virtual c1 &f2();
};
c1 &c3::f2()
{
throw 0;
}
struct c4 : virtual c3
{
}; |
google | chromium | covariant8 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant8.C | 509 | utf_8 | 9a768cc9dfee9447ec4b15a45df32035 | // { dg-do compile }
// ICE with covariant thunks.
struct c0 {};
struct c1 : virtual c0
{
virtual c0 &f2 ();
};
struct c2
{
int m;
};
struct c3 : virtual c0, virtual c1, c2
{
virtual c1 &f2 ();
};
c1 &c3::f2 ()
{
throw 0;
}
struct c4 : virtual c3, virtual c0, virtual c1 {};
struct c8 : virtual c2, virtual c0 {... |
google | chromium | thunk6 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/thunk6.C | 305 | utf_8 | 2dfbca1638b220825eaaf7ab19f120af | // PR c++/26957
struct LongDouble {
char ld[16];
};
struct DynAny {
virtual void insert_longdouble(LongDouble value) = 0;
};
struct TAO_DynCommon : public virtual DynAny {
virtual void insert_longdouble (LongDouble value);
};
void TAO_DynCommon::insert_longdouble (LongDouble value) { }
|
google | chromium | covariant1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant1.C | 396 | utf_8 | d5b9e7987bad7019aaec9e69eab66e85 | // PR c++/5607
// { dg-do run }
class A {
public:
virtual A* getThis() { return this; }
};
class B {
int a;
public:
virtual B* getThis() { return this; }
};
class AB : public A, public B {
public:
virtual AB* getThis() { return this; }
};
int main ()
{
AB* ab = new AB();
A* a = ab;
B* b = ab;
if ... |
google | chromium | volatile1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/volatile1.C | 169 | utf_8 | 768bdcc7042d268b87a11846a928e38c | // PR c++/19299
// { dg-do compile }
struct V
{
virtual void foo() = 0;
};
void bar(V volatile* p)
{
p->V::~V();
} |
google | chromium | template-as-base | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/template-as-base.C | 205 | utf_8 | 11e5d1f68073db04c0dcb3d956d68731 | // Distilled from PR C++/3656
namespace N
{
template<typename> struct X { };
}
struct A : N::X { }; // { dg-error "expected class-name" "" } |
google | chromium | access8 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/access8.C | 163 | utf_8 | 17be1beac7572a9dd41db722b95cd985 | // PR c++/29138
class A
{
public:
int i;
class A1
{
int j;
};
};
class B : private A
{
public:
A::i;
A::A1;
};
void
f ()
{
B b;
B::A1 a1;
}
|
google | chromium | multiple1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/multiple1.C | 266 | utf_8 | 0538ccbaac8b13faa65f78233c14d00f | // { dg-options "-w" }
struct Base {
int b;
Base(int b) : b(b) { }
};
struct Derived : public Base {
Derived(int d) : Base(d) { }
};
struct Final : public Derived, public Base {
Final(int f) : Derived(f), Base(f-1) { }
};
int main()
{
Final f(5);
}
|
google | chromium | covariant12 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant12.C | 325 | utf_8 | 024b0d1452f48d9188fd4c6f01697f03 | // PR 20232: ICE on invalid
struct T { };
struct S;
struct B
{
virtual T *Foo (); // { dg-error "overriding" "" }
};
struct D : B
{
virtual S *Foo (); // { dg-error "invalid covariant" "" }
}; |
google | chromium | base3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/base3.C | 182 | utf_8 | ba2f89caa6630c3d9d4ad4c3e5ff4dff | // PR c++/35985
// { dg-do compile }
template<typename T> struct A : T {}; // { dg-error "struct or class type" }
struct B;
A<void (B::*)()> a; // { dg-message "instantiated" }
|
google | chromium | covariant4 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant4.C | 1,292 | utf_8 | 8c6bb6aaa56fa2bea8b375c52fab5688 | // { dg-do run }
// covariant returns. Fixed & virtual offset.
struct B1;
struct B2;
struct D;
struct B1
{
virtual B1 *foo1 () {return this;}
virtual B2 *foo2 (D *);
};
struct B2
{
virtual B2 *baz1 () {return this;}
virtual B1 *baz2 (D *);
};
struct Pad1 { virtual ~Pad1 (){}};
struct Pad2 { virtual ~Pad2 (){}};... |
google | chromium | local3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/local3.C | 228 | utf_8 | b542b48ead2e56bb6bd2a0ae0f0e435f | // PR c++/13744 (ice-on-valid-code)
// { dg-do compile }
template<int> void foo()
{
struct A
{
virtual void bar() { A a(*this); }
} a;
}
template void foo<0>(); |
google | chromium | covariant16 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant16.C | 261 | utf_8 | b7613959cb5ee7a1eb7dc80a90aa5b20 | /* PR c++/28253 This used to ICE. */
/* { dg-do "compile" } */
struct A
{
virtual A* foo();
};
struct B : virtual A
{
virtual B* foo(); /* { dg-error "overriding" } */
};
struct C : B
{
virtual C& foo(); /* { dg-error "conflicting return type" } */
};
|
google | chromium | thunk4 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/thunk4.C | 194 | utf_8 | 36499d0eccceff40478008f2dc2f180f | // PR c++/21123
struct A
{
A( const A &a);
const A& operator=( const A& a);
};
struct B
{
virtual A f();
};
struct C : virtual B
{
virtual A f();
A a;
};
A C::f()
{
return a;
}
|
google | chromium | cond1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/cond1.C | 169 | utf_8 | f3b3605ed6515de4b142977d92356815 | // { dg-do compile }
struct A { A(); A(const A&); int i; };
struct B: public A { };
int f (bool b, A& ar, B& br)
{
return (b?ar:br).i;
} |
google | chromium | virtual3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/virtual3.C | 160 | utf_8 | 88e3f23768b2dfe530d163660b058796 | //PR c++/29022
struct A
{
operator int();
};
struct B : virtual A; // { dg-error "token" }
int foo(B &b)
{
return b; // { dg-error "cannot convert" }
}
|
google | chromium | covariant3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant3.C | 1,146 | utf_8 | 24ff947b4da8f1fcee6c7b66d8388009 | // { dg-do run }
// covariant returns. Virtual offset.
struct B1;
struct B2;
struct D;
struct B1
{
virtual B1 *foo1 () {return this;}
virtual B2 *foo2 (D *);
};
struct B2
{
virtual B2 *baz1 () {return this;}
virtual B1 *baz2 (D *);
};
struct D : virtual B1, virtual B2
{
virtual D *foo1 () {return this;}
vir... |
google | chromium | access3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/access3.C | 315 | utf_8 | 782f289a8885743348299a4efef52f20 | // { dg-do compile }
class __new_alloc {
public:
static void allocate() {}
};
template <class _Alloc>
class __debug_alloc : public _Alloc {
public:
static void allocate();
};
template <class _Alloc>
void __debug_alloc<_Alloc>::allocate() {
_Alloc::allocate();
}
template class __debug_alloc<__new_alloc>;
|
google | chromium | using4 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/using4.C | 321 | utf_8 | 5fa38874a73026f9b2fd718cdccff27d | struct B {
void f();
};
struct D : B {
using B::f;
using B::f; // { dg-error "repeated" }
}; |
google | chromium | using6 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/using6.C | 316 | utf_8 | 63552e938483cc3badd1eaa4527e92a9 | struct A
{
operator int ();
};
template <typename T> struct TPL : A
{
using A::operator T; // { dg-error "operator float" }
};
TPL<int> i;
TPL<float> j; // { dg-message "instantiated" } |
google | chromium | override-attribs | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/override-attribs.C | 439 | utf_8 | 6ecf23375e5f842e6a47cadf36c7f2d4 | // PR c++/14688
// { dg-do compile { target i?86-*-* x86_64-*-* } }
// { dg-require-effective-target ilp32 }
class one
{
public:
virtual void
test(void* value); // { dg-error "overriding" }
};
class two : public one
{
public:
void __attribute__((regparm(2)))
test(void* value); // { dg-error "conflicting ty... |
google | chromium | error1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/error1.C | 113 | utf_8 | c788c5892d7d120b0357a3804e53f50a | // PR 12486
struct A { int ma; };
struct B { };
void foo()
{
B *b;
b->A::ma=0; // { dg-error "" }
}
|
google | chromium | thunk1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/thunk1.C | 558 | utf_8 | f54f42efb01f78d530cd6440f416587e | // { dg-do run { target i?86-*-* x86_64-*-* s390*-*-* alpha*-*-* ia64-*-* sparc*-*-* } }
#include <stdarg.h>
extern "C" void abort ();
struct A {
virtual void f (int, ...) {}
int i;
};
struct B : virtual public A {
};
struct C : public B {
C ();
virtual void f (int, ...);
};
extern C* cp;
C::C () { cp = ... |
google | chromium | conv3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/conv3.C | 450 | utf_8 | 2306dad7914eaa72347a53252751eb1e | // PR 31074
// Bug: The reference cast wasn't finding the desired static_cast followed by
// const_cast interpretation.
struct Shape
{
Shape() {}
virtual ~Shape() {}
};
struct Loop
{
Loop() {}
virtual ~Loop() {}
virtual void func() {}
};
struct Rect :
public Shape,
public Loop
{
Rect() {}
virtual ~... |
google | chromium | typedef1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/typedef1.C | 105 | utf_8 | 543b190c9c0d744209af04ea332cc27e | namespace NS {
class X {};
typedef X Y;
}
struct Base : virtual public NS::Y {
Base() : NS::Y() {}
};
|
google | chromium | using1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/using1.C | 451 | utf_8 | 68d63fe3703892061d4c4162a5385cdf | // Test that overloading on 'this' quals works with class using-declarations.
// { dg-do link }
struct A {
void f() const;
void f() {}
void g() const {}
void g();
void h() const;
void h();
void i() const;
void i() {}
};
struct B: private A {
using A::f;
using A::g;
void h () const {}
using A:... |
google | chromium | ptrmem1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/ptrmem1.C | 388 | utf_8 | 57ff79e4f3304cf12253ad956fe99a96 | // PR c++/14803
// { dg-options "-Werror" }
struct sc_module { int member; };
struct sc_signal_in_if { bool state; };
typedef void (sc_module::*SC_ENTRY_FUNC)();
class sc_clock : public sc_signal_in_if, public sc_module
{
public:
sc_clock();
void posedge_action();
SC_ENTRY_FUNC fptr;
};
sc_clock::sc_clock()
... |
google | chromium | override1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/override1.C | 787 | utf_8 | 1c83e20d447d50159eb23408fda6231f | // { dg-options "-w" }
struct c0 { virtual void f (); };
struct c1 : public c0 {};
struct c2 : public c0 {};
struct c3 : virtual public c0, public c1, public c2 {};
struct c5 {};
struct c7 : virtual public c3 {};
struct c8 : virtual public c1 { virtual void f (); };
struct c9 {};
struct c10 : virtual public c8, virtua... |
google | chromium | covariant2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant2.C | 1,128 | utf_8 | 1a712ed4a3f761571bfe894372a9032b | // { dg-do run }
// covariant returns. Fixed offset.
struct B1;
struct B2;
struct D;
struct B1
{
virtual B1 *foo1 () {return this;}
virtual B2 *foo2 (D *);
};
struct B2
{
virtual B2 *baz1 () {return this;}
virtual B1 *baz2 (D *);
};
struct D : B1, B2
{
virtual D *foo1 () {return this;}
virtual D *foo2 (D *d... |
google | chromium | local2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/local2.C | 151 | utf_8 | 7ba23e93339cef0810a212036425afb3 | // PR c++/17155
// { dg-do link }
struct A {
virtual ~A() {}
};
void tsk_tsk(void)
{
struct B : public A {
B(int) {}
};
}
int main () {}
|
google | chromium | thunk10 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/thunk10.C | 689 | utf_8 | 1207763664f70af366a4b659c0bebe22 | /* { dg-options "-mthumb" { target arm*-*-* } } */
/* { dg-do run } */
/* { dg-timeout 100 } */
/* PR middle-end/39378 */
/* Check if the thunk target function is emitted correctly. */
class B1
{
public:
virtual int foo1(void);
int b1;
};
class B2
{
public:
virtual int foo2 (void);
int b2;
};
class D : publi... |
google | chromium | thunk2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/thunk2.C | 206 | utf_8 | 9b88ac0413e9487e8a758280c835a160 | // PR c++/14108
class ClassC {
public:
~ClassC();
};
class ClassA {
virtual ClassC f();
};
class ClassB : public virtual ClassA {
virtual ClassC f();
};
ClassC ClassB::f() {
return ClassC();
}
|
google | chromium | access2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/access2.C | 197 | utf_8 | 6b97e7f34bed3048a23d0a8e86c3e497 | // Test that a base doesn't get special rights to convert to itself.
struct A {
void f ();
};
struct B: private A { };
B b;
void A::f ()
{
A* ap = &b; // { dg-error "base|inherit" "" }
}
|
google | chromium | local1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/local1.C | 95 | utf_8 | 58a10b4567b6f89d8662c1fc4673d85e | // PR c++/17121
struct A {
virtual ~A() {}
};
void tsk_tsk()
{
struct B : public A {};
}
|
google | chromium | conv2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/conv2.C | 236 | utf_8 | 65847617fa7d1ccf575a8de01815db58 | // PR c++/25895
// { dg-do run }
class base {
public:
base() {}
private:
int val_;
};
class derived : public base {
public:
derived() {}
};
static bool x = true ? (derived*)0 : (base*)0;
int main ()
{
if (x)
return 1;
}
|
google | chromium | typeinfo1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/typeinfo1.C | 251 | utf_8 | be87b303cd68bc0083e229657e8d162a | typedef struct {
virtual const char *blah() {
return "Heya::blah";
}
} Heya;
struct Grok : public Heya {
virtual const char *blah() {
return "Grok::blah";
}
};
int main() {
Grok *g = new Grok();
delete g;
return 0;
}
|
google | chromium | operator1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/operator1.C | 474 | utf_8 | 47a2c8a75fa7e8806502df721a9bf6e3 | // Test that conversions to base classes happen when calling
// operators.
// { dg-do run }
extern "C" void abort ();
struct B1;
struct B2;
B2* p;
B1* p2;
struct B1 {
virtual void f () {}
};
struct B2 {
int i;
bool operator!() { if (this != p) abort (); return true; }
operator void*() { if (this != p) abo... |
google | chromium | pr30297 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/pr30297.C | 108 | utf_8 | babde01c5bf6aa9c4fb004bd731b3107 | // Regression test for ICE from PR c++/30297.
struct A
{
int i;
};
extern "C" struct B : A
{
A::i;
};
|
google | chromium | thunk9 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/thunk9.C | 156 | utf_8 | fb6adb819d82abbffb1f0f36f85868ba | // PR tree-optimization/37095
// { dg-options "-O" }
struct A
{
virtual A *foo ();
};
struct B : virtual A
{
virtual B *foo () { return 0; }
};
B b;
|
google | chromium | base1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/base1.C | 465 | utf_8 | 953df2b1556d4072e312369e3d7273a1 | // { dg-do compile }
// { dg-options "-pedantic-errors -w" }
// PR 164
// Although a direct base can be inaccessible due to ambiguity, that
// should not blow up synthesized methods.
struct A {int m;};
struct B : A {int m;};
struct C : virtual A, B {int m;};
struct D : B, C {int m;};
void foo2 ()
{
D d;
D e (d);
... |
google | chromium | covariant14 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/inherit/covariant14.C | 369 | utf_8 | 50c88ef50589e6c43504bf35e1780d9c | struct A;
struct B
{
virtual A* foo(); // { dg-error "overriding" "" }
};
namespace N
{
struct A : B
{
virtual A* foo(); // { dg-error "invalid covariant" "" }
};
} |
google | chromium | for-18 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/for-18.C | 1,266 | utf_8 | 346ebf6198dbf562511da712952ea387 | // { dg-do compile }
extern int bar (int);
void
foo (void)
{
int j, k = 1, l = 30, m = 4;
long int o = 4;
long long int p = 0;
#pragma omp for
for (j = k; j <= l; j += m - 1)
;
#pragma omp for
for (j = k; j <= l; j += (m - 1))
;
#pragma omp for
for (j = k; j <= l; j += bar (m - 1))
;
#pragma om... |
google | chromium | barrier-2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/barrier-2.C | 219 | utf_8 | a410aa2b8862c24cecd923f5b96ea983 | // { dg-do compile }
void f1(void)
{
#pragma omp barrier a // { dg-error "expected end of line" }
}
void f3(bool p)
{
if (p)
#pragma omp barrier // { dg-error "compound statements" }
} // { dg-error "" }
|
google | chromium | atomic-10 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/atomic-10.C | 521 | utf_8 | 965328e0df7ea1eac39b1c9ed586468c | // PR middle-end/28046
// { dg-do compile }
// { dg-options "-fopenmp -fdump-tree-ompexp" }
int a[3], b;
struct C { int x; int y; } c;
int bar (void), *baz (void);
void
foo (void)
{
#pragma omp atomic
a[2] += bar ();
#pragma omp atomic
b += bar ();
#pragma omp atomic
c.y += bar ();
#pragma omp atomic
*baz ()... |
google | chromium | block-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-1.C | 415 | utf_8 | facd777b68c6d12564f4a64e8e63b4bd | // { dg-do compile }
void foo()
{
bad1: // { dg-error "jump to label" }
#pragma omp parallel
goto bad1; // { dg-error "from here|exits OpenMP" }
goto bad2; // { dg-error "from here" }
#pragma omp parallel
{
bad2: ; // { dg-error "jump to label|enters OpenMP" }
}
#pragma omp paral... |
google | chromium | pr31769 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr31769.C | 789 | utf_8 | 3f2f7d7e2c0fbef3bab6faf28be630dd | // PR tree-optimization/31769
// { dg-options "-O2 -fopenmp" }
// { dg-do compile }
struct B
{
B () {}
virtual ~B () {}
};
struct C
{
C (int x, int y) {}
};
template<typename T, int U>
struct D
{
D () {}
~D () {}
};
struct E
{
E () {}
~E () {}
D<int, 1> e;
};
struct A
{
B *b;
A () { b = __null; }
... |
google | chromium | block-5 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-5.C | 242 | utf_8 | e1b610b24e3322ec263df56fc2a48224 | // { dg-do compile }
void foo()
{
#pragma omp master
{
goto bad1; // { dg-error "from here" }
}
#pragma omp master
{
bad1: // { dg-error "jump|exits OpenMP" }
return; // { dg-error "invalid exit" }
}
}
|
google | chromium | pr33333 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr33333.C | 198 | utf_8 | e334ab702e0e92d75a0f549b1ef34223 | // PR middle-end/33333
// { dg-do compile }
struct A
{
int n;
void foo ();
};
void
A::foo ()
{
try
{
#pragma omp parallel for
for (int i = 0; i < n; ++i)
;
} catch (...) {}
}
|
google | chromium | clause-3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/clause-3.C | 2,992 | utf_8 | d015e3123cdb726fb36852dceb033b8e | // { dg-do compile }
// { dg-require-effective-target tls_native }
#define p parallel
extern void bar (void);
extern char q[]; // { dg-error "has incomplete type" }
int t;
#pragma omp threadprivate (t)
void
foo (int x)
{
char *p;
struct S { int i; int j; } s;
char a[32];
double d;
int i;
const int c = 8;
#p... |
google | chromium | pr26690-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr26690-1.C | 243 | utf_8 | b9c788fe91edddfa242b0d04d51a6012 | // PR c++/26690
// { dg-do compile }
struct A
{ // { dg-message "A::A\\(const A&\\)" }
A (int); // { dg-message "candidates" }
};
void
foo ()
{
A a(0);
#pragma omp parallel private (a) // { dg-error "no matching function" }
;
}
|
google | chromium | parallel-5 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/parallel-5.C | 177 | utf_8 | d9a1f43ca6ac2a073e22bbbf243f300b | // { dg-do compile }
extern void bar (void);
int main (void)
{
int i;
#pragma omp parallel for nowait /* { dg-error "'nowait'" } */
for (i = 0; i < 10; i++)
bar ();
}
|
google | chromium | pr29965-10 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-10.C | 478 | utf_8 | 5711a0429a614d267b03f59eb88887fe | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// This is invalid code, but we don't emit diagnostics for it, nevertheless
// we test that we don't ICE on it.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
void
foo1 ()
{
int i;
#pragma omp for schedule (static... |
google | chromium | pr39495-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr39495-1.C | 1,808 | utf_8 | ed3154b5303e779fa2c64b81f958a2e3 | // PR c/39495
// { dg-do compile }
// { dg-options "-fopenmp" }
#define INT_MIN (-__INT_MAX__ - 1)
#define INT_MAX __INT_MAX__
#define UINT_MAX (2U * __INT_MAX__ + 1)
int
foo (void)
{
int i;
unsigned int u;
#pragma omp for
for (i = INT_MIN + 6; i > INT_MIN + 1; i--)
;
#pragma omp for
for (i = INT_MIN + 6... |
google | chromium | pr35158 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr35158.C | 281 | utf_8 | d9099eeeebd2fd1b31356f255209c119 | // PR c++/35158
// { dg-do compile }
// { dg-options "-fopenmp" }
int main(int argc, char *argv[])
{
#pragma omp parallel for
for (int i(0) ; // { dg-error "parenthesized initialization is not allowed in OpenMP 'for' loop" }
i < 10 ;
i++)
;
return 0;
}
|
google | chromium | pr29965-6 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-6.C | 659 | utf_8 | e4c52ee517b132b822a6172deff5f31c | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
extern void baz () __attribute__ ((noreturn));
void
foo1 ()
{
int i;
#pragma omp for schedule (static, 16)
for (i = 0; i < 2834; i++)
for (;;)
;
}
void
... |
google | chromium | pr30494 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr30494.C | 369 | utf_8 | e247a2fd72bf51bc657ab556931ea098 | // PR middle-end/30494
// { dg-do compile }
int
foo (int n)
{
int i;
#pragma omp for
for (i = 0; i < 6; i++)
{
int v[n], w[n * 3 + i];
v[0] = 1;
w[0] = 2;
}
return 0;
}
int
bar (int n)
{
int i;
#pragma parallel omp for
for (i = 0; i < 6; i++)
{
int v[n], w[n * 3 + i];
... |
google | chromium | pr29965-9 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-9.C | 458 | utf_8 | e95b486012b6b3bf86bc7fbb9abc0634 | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// This is invalid code, but we don't emit diagnostics for it, nevertheless
// we test that we don't ICE on it.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
void
foo1 ()
{
#pragma omp single
throw 0;
}
void
foo... |
google | chromium | tpl-barrier-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/tpl-barrier-1.C | 381 | utf_8 | 32c49551a8a91681d95a89661a00c127 | // PR c++/24735
// { dg-do compile }
// { dg-options "-fopenmp -fdump-tree-gimple" }
template <int> void f1 ()
{
#pragma omp barrier
}
template <int> void f2 (bool p)
{
if (p)
{
#pragma omp barrier
}
}
void f3 ()
{
f1<0> ();
f2<0> (true);
}
// { dg-final { scan-tree-dump-times "GOMP_barrier" 2... |
google | chromium | pr34964 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr34964.C | 165 | utf_8 | 94c3841a16ba0d1b53467b728f040029 | // PR c++/34964
// { dg-do compile }
// { dg-options "-fopenmp" }
char x[] = 0; // { dg-error "initializer fails to determine size" }
#pragma omp threadprivate (x)
|
google | chromium | pr38633 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr38633.C | 170 | utf_8 | 680adc575515d539496b844b663da838 | // PR middle-end/38633
// { dg-do compile }
// { dg-options "-fopenmp" }
void
foo ()
{
#pragma omp parallel
{
struct A { int i; } j;
j.i = 6;
j.i++;
}
}
|
google | chromium | atomic-2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/atomic-2.C | 308 | utf_8 | 02a1665574401bc7491c754880894569 | /* { dg-do compile } */
float x, y;
void f1(void)
{
#pragma omp atomic
x++;
#pragma omp atomic
x--;
#pragma omp atomic
++x;
#pragma omp atomic
--x;
#pragma omp atomic
x += 1;
#pragma omp atomic
x -= y;
#pragma omp atomic
x *= 3;
#pragma omp atomic
x /= 3;
}
|
google | chromium | pr25996 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr25996.C | 540 | utf_8 | 93a85a09acfdf011a86ff95fc9184a94 | // PR c/25996
void
test1 (void)
{
#pragma omp for
for (i = 0; i < 1; ++i); // { dg-error "not declared|expected iteration decl" }
}
void
test2 (void)
{
int i;
#pragma omp for
for (i = j; i < 1; ++i); // { dg-error "not declared|expected iteration decl" }
}
void
test3 (void)
{
int i;
#pragma omp for
for (i ... |
google | chromium | for-3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/for-3.C | 1,625 | utf_8 | 9181a87e2f994d63d21b965bd8baf5ad | // { dg-do compile }
int bar ();
void foo()
{
int i;
#pragma omp for schedule // { dg-error "expected" }
for (i = 0; i < 10; ++i) ;
#pragma omp for schedule static // { dg-error "expected" }
for (i = 0; i < 10; ++i) ;
#pragma omp for schedule ( // { dg-error "invalid schedule kind" }
for (i = 0; i ... |
google | chromium | for-14 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/for-14.C | 420 | utf_8 | 7d78cd8bc009108e1a80c10e65b1560a | // { dg-do compile }
extern int printf (const char *, ...);
extern void foo (int *);
int main (void)
{
double d = 6;
int i = 1, j = 6, k = 8;
#pragma omp parallel shared(d) private(i) num_threads (4)
{
i = 4;
#pragma omp for lastprivate(j)
for (j = 1; j <= k; j++)
printf ("%s %d %d %d %p %g\n", "H... |
google | chromium | tpl-parallel-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/tpl-parallel-1.C | 306 | utf_8 | 3fe09daf99ddda4ea1fef59c61e34f47 | // { dg-do compile }
int check;
template<typename T> void foo()
{
check |= sizeof(T);
}
template<typename T>
void bar(void)
{
#pragma omp parallel if (0)
foo<T>();
}
int main()
{
bar<char>();
bar<short>();
if (check != (sizeof(char) | sizeof(short)))
__builtin_trap ();
return 0;
}
|
google | chromium | macro-3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/macro-3.C | 489 | utf_8 | 79fdf04ca7f5ba718ead3241e68d9e15 | // PR preprocessor/27746
// { dg-do compile }
// { dg-options "-fopenmp -fdump-tree-omplower" }
#define omp FOO
#define p parallel
#define omp_parallel _Pragma ("omp parallel")
#define omp_p _Pragma ("omp p")
void bar (void);
void
foo (void)
{
#pragma omp parallel
bar ();
#pragma omp p
bar ();
omp_p... |
google | chromium | pr35099 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr35099.C | 411 | utf_8 | df86f414ce8746b64631ba22c0bb6773 | // PR middle-end/35099
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
struct A
{
~A () throw ();
void foo ();
};
struct B
{
B () { A ().foo (); }
};
void
bar ()
{
#pragma omp parallel
{
#pragma omp single
B ();
#pragma omp for
for (int i = 0; i < 2; ++i)
B ();
}
}
void
baz ()
{
#p... |
google | chromium | tls-2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/tls-2.C | 275 | utf_8 | 8a54f10a4ae0d0bc2ff3ce7443785073 | /* { dg-do compile } */
/* { dg-require-effective-target tls_native } */
extern char buf[];
#pragma omp threadprivate (buf) /* { dg-error "has incomplete type" } */
void
foo (void)
{
int i;
#pragma omp threadprivate (i) /* { dg-error "automatic variable" } */
i = 0;
}
|
google | chromium | for-17 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/for-17.C | 144 | utf_8 | b0c773d45d10c0af972510732dfd12b4 | /* { dg-do compile } */
void foo()
{
long n = 10;
int i;
#pragma omp for
for (i=0; i < n; ++i) ;
#pragma omp for
for (i=0; n > i; ++i) ;
}
|
google | chromium | tpl-for-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/tpl-for-1.C | 195 | utf_8 | 4a4bf7fb6d4865db8fa5a4940198eab3 | // { dg-do compile }
void foo(int);
void foo(long);
template<typename T> void bar()
{
#pragma omp for
for (T i = 0; i < 10; ++i)
foo(i);
}
void test()
{
bar<int>();
bar<long>();
}
|
google | chromium | pr31598 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr31598.C | 907 | utf_8 | 885878939e0fe4c172763eabac4fd1eb | // PR c++/31598
// { dg-do compile }
//
int i;
template <typename> struct A { A() {} };
template <typename> struct C { C() { i++; } C(const C &) { i += 2; } };
struct D { D() {} };
struct M { typedef double E; };
template <typename T>
struct R
{
R()
{
typedef A<typename T::E> B;
B b;
#pragma omp paralle... |
google | chromium | task-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/task-1.C | 305 | utf_8 | 70dbf976d5a7e8dc72edd6848b9a7c0b | // { dg-do compile }
// { dg-options "-fopenmp" }
struct A { A (); ~A (); int i; };
template <typename T> void bar (T &);
const A a;
void foo (A &p)
{
const A &q = a;
#pragma omp task // { dg-error "has reference type" }
bar (p);
#pragma omp task // { dg-error "has reference type" }
bar (q);
}
|
google | chromium | block-6 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-6.C | 117 | utf_8 | c3c132c63e769145d5869a1e0c14f686 | // { dg-do compile }
void foo()
{
#pragma omp ordered
{
return; // { dg-error "invalid exit" }
}
}
|
google | chromium | block-2 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-2.C | 594 | utf_8 | 749c0d72d29b4aa9f516385858834ab5 | // { dg-do compile }
void foo()
{
int i, j;
#pragma omp for
for (i = 0; i < 10; ++i)
break; // { dg-error "break" }
bad1: // { dg-error "jump to label" }
#pragma omp for
for (i = 0; i < 10; ++i)
goto bad1; // { dg-error "from here|exits OpenMP" }
goto bad2; // { dg-error "from here" }... |
google | chromium | pr29965-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-1.C | 442 | utf_8 | b9a2699c36611930a6cd985b859b64d7 | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
extern void baz () __attribute__ ((noreturn));
static inline void
foo ()
{
#pragma omp parallel
for (;;)
;
}
static inline void
bar ()
{
#pragma omp parallel
... |
google | chromium | pr29965-5 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-5.C | 643 | utf_8 | ca06637df1998d16f119f8d27a3e6acb | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
extern void baz () __attribute__ ((noreturn));
void
foo1 ()
{
int i;
#pragma omp for schedule (static)
for (i = 0; i < 2834; i++)
for (;;)
;
}
void
bar1... |
google | chromium | block-7 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-7.C | 543 | utf_8 | 21fde38c324f474c2251280d6cd9a190 | // { dg-do compile }
void foo()
{
int i, j;
for (i = 0; i < 10; ++i)
{
#pragma omp for
for (j = ({ continue; 0; }); // { dg-error "invalid exit" }
j < ({ continue; 10; }); // { dg-error "invalid exit" }
j += ({ continue; 1; })) // { dg-error "invalid exit" }
continue;
#pragma omp fo... |
google | chromium | for-13 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/for-13.C | 417 | utf_8 | f722f05e29cf6d22080b5ed5f3b0ac7a | // At one point in development, a typo disabled the remapping of the
// for iteration variable as private.
// { dg-do compile }
// { dg-options "-fopenmp -fdump-tree-lower" }
extern void bar(int);
void foo(void)
{
int i;
#pragma omp parallel for default(none)
for (i = 0; i < 10; i++)
bar(i);
}
// { dg-final... |
google | chromium | tls-4 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/tls-4.C | 280 | utf_8 | 92bd9af6ef9d0192139b06f9aac7fee0 | // { dg-do compile }
// { dg-require-effective-target tls_native }
#define thr threadprivate
struct S
{
static int s;
};
struct T : public S
{
static int t;
#pragma omp thr (s) // { dg-error "directive not in" }
};
#pragma omp thr (T::t) // { dg-error "directive not in" }
|
google | chromium | predetermined-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/predetermined-1.C | 896 | utf_8 | d2c2484d4d1236326efc32a01fddaa03 | // { dg-do compile }
// { dg-options "-fopenmp" }
struct A { int i; A (); ~A (); };
struct B { int i; };
struct C { int i; mutable int j; C (); ~C (); };
template <typename T> void bar (const T *);
const A a;
const C c;
const A foo (const A d, const C e)
{
const A f;
const B b = { 4 };
A g;
#pragma omp para... |
google | chromium | sections-4 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/sections-4.C | 203 | utf_8 | e37bc065af06feeda20c2806a2456d89 | /* PR c++/24613 */
/* { dg-compile } */
#pragma omp section /* { dg-error "may only be used in" } */
int i;
void
foo (void)
{
#pragma omp section /* { dg-error "may only be used in" } */
i++;
}
|
google | chromium | block-11 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-11.C | 230 | utf_8 | 64de75e0ae05fb493c94bd4478f76721 | /* PR c++/24516 */
/* { dg-do compile } */
void
bar (int *p)
{
int m;
#pragma omp parallel for
for (m = 0; m < 1000; ++m)
switch (p[m])
{
case 1:
p[m] = 2;
break;
default:
p[m] = 3;
break;
}
}
|
google | chromium | master-1 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/master-1.C | 350 | utf_8 | 9dff449fe2d97c4b3ade07b982e69364 | /* { dg-do compile } */
extern void bar(int);
void foo (void)
{
#pragma omp master
bar(0);
#pragma omp master
{
bar(1);
bar(2);
}
/* Yes, this is legal -- structured-block contains statement contains
openmp-construct contains master-construct. */
#pragma omp master
#pragma omp master... |
google | chromium | pr29965-3 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-3.C | 589 | utf_8 | 2d9f346cbd057f0a16724783281b8d57 | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
extern void baz () __attribute__ ((noreturn));
void
foo1 ()
{
#pragma omp single
for (;;);
}
void
bar1 ()
{
#pragma omp single
baz ();
}
void
foo2 ()
{
#pragma o... |
google | chromium | block-9 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/block-9.C | 603 | utf_8 | 7eeef2596c8e7707166a82efbfbb8e2c | // { dg-do compile }
void foo(int i)
{
int j;
switch (i)
{
#pragma omp parallel
{ case 0:; } // { dg-error "jump|enters" }
#pragma omp for
for (j = 0; j < 10; ++ j)
{ case 1:; } // { dg-error "jump|enters" }
#pragma omp critical
{ case 2:; } // { dg-error "jump|enters" }
#pragma omp ... |
google | chromium | pr29965-8 | .C | native_client/nacl-gcc/gcc/testsuite/g++.dg/gomp/pr29965-8.C | 1,029 | utf_8 | 6905a61647fa8768928712f5ba22d8da | // PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// This is invalid code, but we don't emit diagnostics for it, nevertheless
// we test that we don't ICE on it.
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
void
foo1 ()
{
#pragma omp sections
{
throw 0;
}... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.