mirror of
https://github.com/gcc-mirror/gcc.git
synced 2024-11-21 13:40:47 +00:00
e4f2f46e01
Removing the assert in trans-expr, lead to initial strides not set which is now fixed. When the array needs repacking, this is done for class arrays now, too. Packing class arrays was done using the regular internal pack function in the past. But that does not use the vptr's copy function and breaks OOP paradigms (e.g. deep copy). The new un-/pack_class functions use the vptr's copy functionality to implement OOP paradigms correctly. PR fortran/96992 gcc/fortran/ChangeLog: * trans-array.cc (gfc_trans_array_bounds): Set a starting stride, when descriptor expects a variable for the stride. (gfc_trans_dummy_array_bias): Allow storage association for dummy class arrays, when they are not elemental. (gfc_conv_array_parameter): Add more general class support and packing for classes, too. * trans-array.h (gfc_conv_array_parameter): Add lbound shift for class arrays. * trans-decl.cc (gfc_build_builtin_function_decls): Add decls for internal_un-/pack_class. * trans-expr.cc (gfc_reset_vptr): Allow supplying a type-tree to generate the vtab from. (gfc_class_set_vptr): Allow supplying a class-tree to take the vptr from. (class_array_data_assign): Rename to gfc_class_array_data_assign and make usable from other compile units. (gfc_class_array_data_assign): Renamed from class_array_data_ assign. (gfc_conv_derived_to_class): Remove assert to allow converting derived to class type arrays with assumed rank. Reduce code base and use gfc_conv_array_parameter also for classes. (gfc_conv_class_to_class): Use gfc_class_data_assign. (gfc_conv_procedure_call): Adapt to new signature of gfc_conv_derived_to_class. * trans-io.cc (transfer_expr): Same. * trans-stmt.cc (trans_associate_var): Same. * trans.h (gfc_conv_derived_to_class): Signature changed. (gfc_class_array_data_assign): Made public. (gfor_fndecl_in_pack_class): Added declaration. (gfor_fndecl_in_unpack_class): Same. libgfortran/ChangeLog: * Makefile.am: Add in_un-/pack_class.c to build. * Makefile.in: Regenerated from Makefile.am. * gfortran.map: Added new functions and bumped ABI. * libgfortran.h (GFC_CLASS_T): Added for generating class representation at runtime. * runtime/in_pack_class.c: New file. * runtime/in_unpack_class.c: New file. gcc/testsuite/ChangeLog: * gfortran.dg/class_dummy_11.f90: New test. |
||
---|---|---|
.github | ||
c++tools | ||
config | ||
contrib | ||
fixincludes | ||
gcc | ||
gnattools | ||
gotools | ||
include | ||
INSTALL | ||
libada | ||
libatomic | ||
libbacktrace | ||
libcc1 | ||
libcody | ||
libcpp | ||
libdecnumber | ||
libffi | ||
libgcc | ||
libgfortran | ||
libgm2 | ||
libgo | ||
libgomp | ||
libgrust | ||
libiberty | ||
libitm | ||
libobjc | ||
libphobos | ||
libquadmath | ||
libsanitizer | ||
libssp | ||
libstdc++-v3 | ||
libvtv | ||
lto-plugin | ||
maintainer-scripts | ||
zlib | ||
.dir-locals.el | ||
.gitattributes | ||
.gitignore | ||
ABOUT-NLS | ||
ar-lib | ||
ChangeLog | ||
ChangeLog.jit | ||
ChangeLog.tree-ssa | ||
compile | ||
config-ml.in | ||
config.guess | ||
config.rpath | ||
config.sub | ||
configure | ||
configure.ac | ||
COPYING | ||
COPYING3 | ||
COPYING3.LIB | ||
COPYING.LIB | ||
COPYING.RUNTIME | ||
depcomp | ||
install-sh | ||
libtool-ldflags | ||
libtool.m4 | ||
lt~obsolete.m4 | ||
ltgcc.m4 | ||
ltmain.sh | ||
ltoptions.m4 | ||
ltsugar.m4 | ||
ltversion.m4 | ||
MAINTAINERS | ||
Makefile.def | ||
Makefile.in | ||
Makefile.tpl | ||
missing | ||
mkdep | ||
mkinstalldirs | ||
move-if-change | ||
multilib.am | ||
README | ||
SECURITY.txt | ||
symlink-tree | ||
test-driver | ||
ylwrap |
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.