8209db250f
Given the following invalid arm_neon.h-based code: float x; int8x8_t y = x; the error message we emit is pretty good: incompatible types when initializing type 'int8x8_t' using type 'float' But convert the types to pointers: int8x8_t *ptr = &x; and the message becomes: initialization of '__vector(8) signed char *' from incompatible pointer type 'float *' Although it's reasonably obvious what '__vector(8) signed char *' means, it isn't valid C or C++ syntax and is quite far from what the user wrote, so using 'int8x8_t *' would be better. This patch therefore prints the type name of vectors that have one. It's still OK to print the __vector syntax as an "aka", although I have a follow-on patch to tweak this slightly for types defined in system header files. The follow-on patch also addresses the ??? in gcc.target/aarch64/diag_aka_1.c. The C++ test already passed, but it seemed worth including for consistency. 2019-10-01 Richard Sandiford <richard.sandiford@arm.com> gcc/c-family/ * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type has a type name, use it in preference to the __vector syntax. gcc/testsuite/ * gcc.dg/diag-aka-3.c: New test. * gcc.target/aarch64/diag_aka_1.c: New test. * g++.dg/diagnostic/aka4.C: New test. From-SVN: r276394 |
||
---|---|---|
INSTALL | ||
config | ||
contrib | ||
fixincludes | ||
gcc | ||
gnattools | ||
gotools | ||
include | ||
intl | ||
libada | ||
libatomic | ||
libbacktrace | ||
libcc1 | ||
libcpp | ||
libdecnumber | ||
libffi | ||
libgcc | ||
libgfortran | ||
libgo | ||
libgomp | ||
libhsail-rt | ||
libiberty | ||
libitm | ||
libobjc | ||
liboffloadmic | ||
libphobos | ||
libquadmath | ||
libsanitizer | ||
libssp | ||
libstdc++-v3 | ||
libvtv | ||
lto-plugin | ||
maintainer-scripts | ||
zlib | ||
.dir-locals.el | ||
.gitattributes | ||
.gitignore | ||
ABOUT-NLS | ||
COPYING | ||
COPYING.LIB | ||
COPYING.RUNTIME | ||
COPYING3 | ||
COPYING3.LIB | ||
ChangeLog | ||
ChangeLog.jit | ||
ChangeLog.tree-ssa | ||
MAINTAINERS | ||
Makefile.def | ||
Makefile.in | ||
Makefile.tpl | ||
README | ||
ar-lib | ||
compile | ||
config-ml.in | ||
config.guess | ||
config.rpath | ||
config.sub | ||
configure | ||
configure.ac | ||
depcomp | ||
install-sh | ||
libtool-ldflags | ||
libtool.m4 | ||
ltgcc.m4 | ||
ltmain.sh | ||
ltoptions.m4 | ||
ltsugar.m4 | ||
ltversion.m4 | ||
lt~obsolete.m4 | ||
missing | ||
mkdep | ||
mkinstalldirs | ||
move-if-change | ||
multilib.am | ||
symlink-tree | ||
test-driver | ||
ylwrap |
README
This directory contains the GNU Compiler Collection (GCC). The GNU Compiler Collection is free software. See the files whose names start with COPYING for copying permission. The manuals, and some of the runtime libraries, are under different terms; see the individual source files for details. The directory INSTALL contains copies of the installation information as HTML and plain text. The source of this information is gcc/doc/install.texi. The installation information includes details of what is included in the GCC sources and what files GCC installs. See the file gcc/doc/gcc.texi (together with other files that it includes) for usage and porting information. An online readable version of the manual is in the files gcc/doc/gcc.info*. See http://gcc.gnu.org/bugs/ for how to report bugs usefully. Copyright years on GCC source files may be listed using range notation, e.g., 1987-2012, indicating that every year in the range, inclusive, is a copyrightable year that could otherwise be listed individually.