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
74 lines
2.0 KiB
C
74 lines
2.0 KiB
C
// RUN: %clang_cc1 -fsyntax-only -verify -Wfour-char-constants -pedantic -ftrigraphs %s
|
|
|
|
int x = 000000080; // expected-error {{invalid digit}}
|
|
|
|
int y = 0000\
|
|
00080; // expected-error {{invalid digit}}
|
|
|
|
|
|
|
|
float X = 1.17549435e-38F;
|
|
float Y = 08.123456;
|
|
|
|
// PR2252
|
|
#if -0x8000000000000000 // should not warn.
|
|
#endif
|
|
#if -01000000000000000000000 // should not warn.
|
|
#endif
|
|
#if 9223372036854775808 // expected-warning {{integer literal is too large to be represented in a signed integer type, interpreting as unsigned}}
|
|
#endif
|
|
#if 0x10000000000000000 // expected-error {{integer literal is too large to be represented in any integer type}}
|
|
#endif
|
|
|
|
int c[] = {
|
|
'df', // expected-warning {{multi-character character constant}}
|
|
'\t',
|
|
'\\
|
|
t',
|
|
'??!', // expected-warning {{trigraph converted to '|' character}}
|
|
'abcd' // expected-warning {{multi-character character constant}}
|
|
};
|
|
|
|
// PR4499
|
|
int m0 = '0';
|
|
int m1 = '\\\''; // expected-warning {{multi-character character constant}}
|
|
int m2 = '\\\\'; // expected-warning {{multi-character character constant}}
|
|
int m3 = '\\\
|
|
';
|
|
|
|
|
|
#pragma clang diagnostic ignored "-Wmultichar"
|
|
|
|
int d = 'df'; // no warning.
|
|
int e = 'abcd'; // still warn: expected-warning {{multi-character character constant}}
|
|
|
|
#pragma clang diagnostic ignored "-Wfour-char-constants"
|
|
|
|
int f = 'abcd'; // ignored.
|
|
|
|
float t0[] = {
|
|
1.9e20f,
|
|
1.9e-20f,
|
|
1.9e50f, // expected-warning {{too large}}
|
|
1.9e-50f, // expected-warning {{too small}}
|
|
-1.9e20f,
|
|
-1.9e-20f,
|
|
-1.9e50f, // expected-warning {{too large}}
|
|
-1.9e-50f // expected-warning {{too small}}
|
|
};
|
|
double t1[] = {
|
|
1.9e50,
|
|
1.9e-50,
|
|
1.9e500, // expected-warning {{too large}}
|
|
1.9e-500, // expected-warning {{too small}}
|
|
-1.9e50,
|
|
-1.9e-50,
|
|
-1.9e500, // expected-warning {{too large}}
|
|
-1.9e-500 // expected-warning {{too small}}
|
|
};
|
|
|
|
// PR7888
|
|
double g = 1e100000000; // expected-warning {{too large}}
|
|
|
|
char h = '\u1234'; // expected-error {{character too large for enclosing character literal type}}
|