Home | History | Annotate | Download | only in SemaCXX

Lines Matching refs:const_cast

27   char ***var2 = const_cast<cppp>(var);
30 char ***&var4 = const_cast<cpppr>(var3);
32 char *** var5 = const_cast<cppp>(var4);
35 int (&rar)[100] = const_cast<iarr>(ar);
37 int *pi = const_cast<int*>(ar);
40 f *fpp = const_cast<f*>(&fp);
42 int A::* A::* iapap = const_cast<int A::* A::*>(icapcap);
43 (void)const_cast<A&&>(A());
53 char **var2 = const_cast<char**>(var); // expected-error {{const_cast from 'const char *volatile *const volatile *' to 'char **' is not allowed}}
55 short ***var3 = const_cast<short***>(var); // expected-error {{const_cast from 'const char *volatile *const volatile *' to 'short ***' is not allowed}}
57 char ***&var4 = const_cast<cpppr>(&var2); // expected-error {{const_cast from rvalue to reference type 'cpppr'}}
59 char v = const_cast<char>(**var2); // expected-error {{const_cast to 'char', which is not a reference, pointer-to-object, or pointer-to-data-member}}
62 int *(*rar)[100] = const_cast<int *(*)[100]>(&ar); // expected-error {{const_cast from 'const int *(*)[100]' to 'int *(*)[100]' is not allowed}}
65 f fp2 = const_cast<f>(fp1); // expected-error {{const_cast to 'f' (aka 'int (*)(int)'), which is not a reference, pointer-to-object, or pointer-to-data-member}}
67 (void)const_cast<void (A::*)()>(mfn); // expected-error-re {{const_cast to 'void (A::*)(){{( __attribute__\(\(thiscall\)\))?}}', which is not a reference, pointer-to-object, or pointer-to-data-member}}
68 (void)const_cast<int&&>(0); // expected-error {{const_cast from rvalue to reference type 'int &&'}}
76 char *PR21845() { return const_cast<char *>((void)T::x); } // expected-error {{const_cast from 'void' to 'char *' is not allowed}}