brintos

brintos / llvm-project-archived public Read only

0
0
Text · 515 B · 6ad1466 Raw
15 lines · cpp
1// RUN: %clang_cc1 %s -verify -fsyntax-only2// RUN: %clang_cc1 %s -verify -fsyntax-only -fno-signed-char3 4void plainToSigned() {5  extern char c;6  signed char *p;7  p = &c; // expected-error {{converts between pointers to integer types where one is of the unique plain 'char' type and the other is not}}8}9 10void unsignedToPlain() {11  extern unsigned char uc;12  char *p;13  p = &uc; // expected-error {{converts between pointers to integer types where one is of the unique plain 'char' type and the other is not}}14}15