CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
49 lines
1.7 KiB
C++
49 lines
1.7 KiB
C++
// RUN: %clang_cc1 -fsyntax-only -verify %s
|
|
|
|
// PR6647
|
|
class C {
|
|
// After the error, the rest of the tokens inside the default arg should be
|
|
// skipped, avoiding a "expected ';' after class" after 'undecl'.
|
|
void m(int x = undecl + 0); // expected-error {{use of undeclared identifier 'undecl'}}
|
|
};
|
|
|
|
typedef struct Inst {
|
|
void m(int x=0);
|
|
} *InstPtr;
|
|
|
|
struct X {
|
|
void f(int x = 1:); // expected-error {{unexpected end of default argument expression}}
|
|
};
|
|
|
|
// PR13657
|
|
struct T {
|
|
template <typename A, typename B> struct T1 { enum {V};};
|
|
template <int A, int B> struct T2 { enum {V}; };
|
|
template <int, int> static int func(int);
|
|
|
|
|
|
void f1(T1<int, int> = T1<int, int>());
|
|
void f2(T1<int, double> = T1<int, double>(), T2<0, 5> = T2<0, 5>());
|
|
void f3(int a = T2<0, (T1<int, int>::V > 10) ? 5 : 6>::V, bool b = 4<5 );
|
|
void f4(bool a = 1 < 0, bool b = 2 > 0 );
|
|
void f5(bool a = 1 > T2<0, 0>::V, bool b = T1<int,int>::V < 3, int c = 0);
|
|
void f6(bool a = T2<0,3>::V < 4, bool b = 4 > T2<0,3>::V);
|
|
void f7(bool a = T1<int, bool>::V < 3);
|
|
void f8(int = func<0,1<2>(0), int = 1<0, T1<int,int>(int) = 0);
|
|
};
|
|
|
|
struct S {
|
|
void f(int &r = error); // expected-error {{use of undeclared identifier 'error'}}
|
|
};
|
|
|
|
struct U {
|
|
void i(int x = ) {} // expected-error{{expected expression}}
|
|
typedef int *fp(int x = ); // expected-error{{default arguments can only be specified for parameters in a function declaration}}
|
|
};
|
|
|
|
namespace GH196725 {
|
|
template <class T> void f();
|
|
template <> void f<int>(int = []{ ; return 0; }()) {} // expected-error{{no function template matches function template specialization 'f'}} \
|
|
// expected-note@-1{{candidate template ignored}}
|
|
}
|