File: udlit-implicit-conv-neg.C

package info (click to toggle)
gcc-arm-none-eabi 15%3A14.2.rel1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,099,328 kB
  • sloc: cpp: 3,627,108; ansic: 2,571,498; ada: 834,230; f90: 235,082; makefile: 79,231; asm: 74,984; xml: 51,692; exp: 39,736; sh: 33,298; objc: 15,629; python: 15,069; fortran: 14,429; pascal: 7,003; awk: 5,070; perl: 3,106; ml: 285; lisp: 253; lex: 204; haskell: 135
file content (63 lines) | stat: -rw-r--r-- 3,521 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
// { dg-do compile { target c++11 } }

#include <cstdint>

int operator"" _bar (long double);

double operator"" _foo (long long unsigned);

int i = 12_bar; // { dg-error "unable to find numeric literal operator|with|argument" }

double d = 1.2_foo; // { dg-error "unable to find numeric literal operator|with|argument" }

int operator"" _char(char);

int operator"" _wchar_t(wchar_t);

int operator"" _char16_t(char16_t);

int operator"" _char32_t(char32_t);

int cwcx = 'c'_wchar_t; // { dg-error "unable to find character literal operator|with|argument" }
int cc16 = 'c'_char16_t; // { dg-error "unable to find character literal operator|with|argument" }
int cc32 = 'c'_char32_t; // { dg-error "unable to find character literal operator|with|argument" }

int wccx = L'c'_char; // { dg-error "unable to find character literal operator|with|argument" }
int wcc16 = L'c'_char16_t; // { dg-error "unable to find character literal operator|with|argument" }
int wcc32 = L'c'_char32_t; // { dg-error "unable to find character literal operator|with|argument" }

int c16c = u'c'_char; // { dg-error "unable to find character literal operator|with|argument" }
int c16wc = u'c'_wchar_t; // { dg-error "unable to find character literal operator|with|argument" }
int c16c32 = u'c'_char32_t; // { dg-error "unable to find character literal operator|with|argument" }

int c32c = U'c'_char; // { dg-error "unable to find character literal operator|with|argument" }
int c32wc = U'c'_wchar_t; // { dg-error "unable to find character literal operator|with|argument" }
int c32c16 = U'c'_char16_t; // { dg-error "unable to find character literal operator|with|argument" }

int operator"" _char_str(const char*, std::size_t);

int operator"" _wchar_t_str(const wchar_t*, std::size_t);

int operator"" _char16_t_str(const char16_t*, std::size_t);

int operator"" _char32_t_str(const char32_t*, std::size_t);

int strwstr = "str"_wchar_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int strstr16 = "str"_char16_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int strstr32 = "str"_char32_t_str; // { dg-error "unable to find string literal operator|with|arguments" }

int str8wstr = u8"str"_wchar_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int str8str16 = u8"str"_char16_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int str8str32 = u8"str"_char32_t_str; // { dg-error "unable to find string literal operator|with|arguments" }

int wstrstr = L"str"_char_str; // { dg-error "unable to find string literal operator|with|arguments" }
int wstrstr16 = L"str"_char16_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int wstrstr32 = L"str"_char32_t_str; // { dg-error "unable to find string literal operator|with|arguments" }

int str16str = u"str"_char_str; // { dg-error "unable to find string literal operator|with|arguments" }
int str16wstr = u"str"_wchar_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int str16str32 = u"str"_char32_t_str; // { dg-error "unable to find string literal operator|with|arguments" }

int str32str = U"str"_char_str; // { dg-error "unable to find string literal operator|with|arguments" }
int str32wstr = U"str"_wchar_t_str; // { dg-error "unable to find string literal operator|with|arguments" }
int str32str16 = U"str"_char16_t_str; // { dg-error "unable to find string literal operator string operator|with|arguments" }