Go to file
Dodji Seketeli aa373032bf re PR c++/14777 (typedef doesn't fully expose base class type)
Fix PR c++/14777

gcc/cp/ChangeLog:

	PR c++/14777
	* cp-tree.def <TEMPLATE_INFO>: Declare new kind of tree
	node.
	* cp-tree.h (struct tree_template_info,
	struct qualified_typedef_usage_s): New.
	(cp_tree_node_structure_enum): add TS_CP_TEMPLATE_INFO.
	(union lang_tree_node): Add template_info.
	(TI_TEMPLATE, TI_ARGS, TI_TYPEDEFS_NEEDING_ACCESS_CHECKING):
	Adjust.
	(build_template_info): Declare.
	(get_types_needing_access_check): Adjust return type.
	(add_typedef_to_current_template_for_access_check): Declare.
	* cp-objcp-common.c (cp_tree_size): Handle TEMPLATE_INFO.
	* semantics.c (add_typedef_to_current_template_for_access_check):
	Split from ...
	(check_accessibility_of_qualified_id): ... here.
	* decl.c (make_typename_type): Use it.
	* pt.c (build_template_info): Define.
	(check_explicit_specialization, find_parameter_packs_r,
	push_template_decl_real, lookup_template_class,
	for_each_template_parm_r, tsubst_decl, tsubst): Use
	build_template_info.
	(get_types_needing_access_check): Adjust return type.
	(append_type_to_template_for_access_check_1): Record the
	location of the usage point of the typedef. Adjust to TEMPLATE_INFO.
	(append_type_to_template_for_access_check): Add new location
	parameter. Pass it to append_type_to_template_for_access_check_1.
	Adjust to TEMPLATE_INFO.
	(perform_typedefs_access_check): Temporarily set input_location to
	the usage point of the typedef we are checking access for. Adjust
	to new TEMPLATE_INFO tree node.
	* tree.c (bind_template_template_parm): Use build_template_info.
	* call.c (add_template_candidate_real): Likewise.
	* decl.c (grokfndecl): Likewise.
	(cp_tree_node_structure): Handle TEMPLATE_INFO.

gcc/testsuite/ChangeLog:

	PR c++/14777
	* g++.dg/template/typedef13.C: Adjust.
	* g++.dg/template/typedef19.C: Adjust.
	* g++.dg/template/typedef20.C: Adjust.
	* g++.dg/template/typedef22.C: New test.

From-SVN: r154443
2009-11-23 14:29:50 +01:00
boehm-gc Override all per-target *_LINK variables correctly. 2009-09-11 05:02:20 +00:00
config * largefile.m4 (ACX_LARGEFILE): Call AC_PLUGINS. 2009-11-09 23:17:54 +00:00
contrib Merge lto branch into trunk. 2009-10-03 17:10:11 -04:00
fixincludes inclhack.def (hpux_stdint_least_fast): Simplify. 2009-10-21 17:01:35 +00:00
gcc re PR c++/14777 (typedef doesn't fully expose base class type) 2009-11-23 14:29:50 +01:00
gnattools Update AC_PREREQ entries to 2.64 2009-08-24 19:08:51 +00:00
include Checking this in for: Jonas Maebe <jonas.maebe@elis.ugent.be> 2009-11-06 14:36:57 +00:00
INSTALL
intl 2009-10-15 Jim Blandy <jimb@red-bean.com> 2009-10-15 08:56:02 +00:00
libada Makefile.in (GNATLIBCFLAGS_FOR_C): New variable. 2009-10-24 10:58:31 +00:00
libcpp macro.c (enter_macro_context): Call cb.used callback if defined. 2009-11-20 09:18:16 +01:00
libdecnumber stdint.m4 (GCC_HEADER_STDINT): Revert changes to this macro in the previous two patches. 2009-09-09 19:42:21 +00:00
libffi re PR libffi/41908 (closures fail for some structure arguments containing floats) 2009-11-02 22:18:17 +01:00
libgcc re PR other/39888 (TLS emutls not linked to automatically on Darwin) 2009-11-18 08:36:12 +01:00
libgfortran Move includes after include guards 2009-11-19 22:23:03 +02:00
libgomp re PR middle-end/42029 (ICE with complex data type and openmp for reduction clause) 2009-11-13 19:38:36 +01:00
libiberty pex-unix.c (pex_child_error): Improve warning avoidance by checking the results of write(3) and exiting with... 2009-11-23 15:42:32 +11:00
libjava posix-threads.cc (park): Rewrite code to handle time. 2009-11-17 18:05:00 +00:00
libmudflap re PR libmudflap/41433 (security: mudflap accepts environment variables if setuid) 2009-09-22 16:17:50 +00:00
libobjc Update AC_PREREQ entries to 2.64 2009-08-24 19:08:51 +00:00
libssp Update AC_PREREQ entries to 2.64 2009-08-24 19:08:51 +00:00
libstdc++-v3 re PR libstdc++/42019 (shared_ptr can not be used with -fno-rtti) 2009-11-20 21:23:02 +00:00
lto-plugin re PR bootstrap/42096 (lto.c:289:7: error: implicit declaration of function 'strtoll') 2009-11-19 15:30:04 +00:00
maintainer-scripts * update_web_docs_svn: Update BUGURL to http://gcc.gnu.org/bugs/. 2009-10-10 20:43:15 +00:00
zlib Update AC_PREREQ entries to 2.64 2009-08-24 19:08:51 +00:00
ABOUT-NLS
ChangeLog configure.ac: Change default of poststage1_ldflags to be empty if poststage1_libs is set. 2009-11-22 04:25:56 +00:00
ChangeLog.tree-ssa
compile
config-ml.in
config.guess * config.guess: Update from upstream sources. 2009-11-20 09:47:13 +11:00
config.rpath
config.sub * config.sub, config.guess: Update from upstream sources. 2009-11-17 05:04:53 +11:00
configure configure.ac: Change default of poststage1_ldflags to be empty if poststage1_libs is set. 2009-11-22 04:25:56 +00:00
configure.ac configure.ac: Change default of poststage1_ldflags to be empty if poststage1_libs is set. 2009-11-22 04:25:56 +00:00
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.RUNTIME
depcomp
install-sh
libtool-ldflags
libtool.m4 libtool.m4 (output_verbose_link_cmd): Require leading blank, and blank before -L. 2009-09-08 17:43:37 +00:00
lt~obsolete.m4
ltgcc.m4
ltmain.sh ltmain.sh (removedotparts): Don't use comma as 's' separator. 2009-08-26 14:52:45 +00:00
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS * MAINTAINERS (Write After Approval): Update my email address. 2009-11-21 20:07:10 +00:00
Makefile.def Makefile.def: Restore host and target settings for gmp. 2009-11-16 22:56:33 +00:00
Makefile.in Makefile.def: Restore host and target settings for gmp. 2009-11-16 22:56:33 +00:00
Makefile.tpl configure.ac: Add libelf to host_libs. 2009-11-16 18:31:10 +00:00
missing
mkdep
mkinstalldirs
move-if-change
README README: Refer to the various COPYING* files instead of just COPYING. 2009-10-10 20:59:49 +00:00
symlink-tree
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.