summaryrefslogtreecommitdiffstats
path: root/libjava/classpath/java/security/PrivateKey.java
diff options
context:
space:
mode:
authordodji <dodji@138bc75d-0d04-0410-961f-82ee72b054a4>2012-11-13 16:07:39 +0000
committerdodji <dodji@138bc75d-0d04-0410-961f-82ee72b054a4>2012-11-13 16:07:39 +0000
commit6262ff17c17973d0d91c843fc5993a00f96cfb9f (patch)
treeec9c5e766874a50e7788247a78b4d686f70b0720 /libjava/classpath/java/security/PrivateKey.java
parent4afab99bf0fe2d6905a9fa9d6ab886ca102312df (diff)
downloadppe42-gcc-6262ff17c17973d0d91c843fc5993a00f96cfb9f.tar.gz
ppe42-gcc-6262ff17c17973d0d91c843fc5993a00f96cfb9f.zip
PR c++/54466 - ICE with alias template which type-id is const qualified
Consider this short example: template<typename T> struct X { }; template<typename T> using Y = const X<T>; using Z = Y<int>; G++ crashes in lookup_class_template_1 while trying to build the alias template instantiation Y<int>. I think this is indirectly due to the fact that that lookup_class_template_1 can now yield a const qualified type like 'const X<T>'. As a consequence, the code in lookup_template_class_1 that was trying to access the TYPE_STUB_DECL field of the result of lookup_template_class_1 should now be adjusted to access the TYPE_STUB_DECL of the main variant of the resulting type instead (and that is TYPE_MAIN_DECL); because qualified types (constructed with build_qualified_type) have their TYPE_STUB_DECL set to NULL. Fixed thus and tested on x86_64-unknown-linux-gnu against trunk. gcc/cp PR c++/54466 * pt.c (lookup_template_class_1): TYPE_STUB_DECL should be accessed on the main variant of the type. gcc/testsuite/ * g++.dg/cpp0x/alias-decl-26.C: New test file. In the example of this patch, g++ crashes when trying to build the alias template Y<int git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@193479 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/classpath/java/security/PrivateKey.java')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud