public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/13929] New: [3.4/3.5 Regression] Segfault in convert_nontype_argument with invalid pointer to member
@ 2004-01-30 11:16 giovannibajo at libero dot it
2004-01-30 11:16 ` [Bug c++/13929] " giovannibajo at libero dot it
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: giovannibajo at libero dot it @ 2004-01-30 11:16 UTC (permalink / raw)
To: gcc-bugs
------------------------------------------
struct S
{
int i;
};
template<int S::*p>
struct X
{
X ();
X(const X<p> &);
};
template <class T>
struct Foo
{
void foo(void)
{
X<&S::i> y = X<&S::NONEXISTENT>();
}
};
------------------------------------------
test.cc:18: internal compiler error: Segmentation fault
I think this is another fallout of two-stage lookup so it should be 3.4/3.5
regression, but can anybody please test this on the 3.3 branch? It works with
3.2.2.
Kriang, I'm CCing you because it might be related to the other segfault you
fixed in convert_nontype_argument (it's still a SCOPE_REF with no type
computed).
--
Summary: [3.4/3.5 Regression] Segfault in
convert_nontype_argument with invalid pointer to member
Product: gcc
Version: 3.5.0
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: giovannibajo at libero dot it
CC: gcc-bugs at gcc dot gnu dot org,lerdsuwa at users dot
sourceforge dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13929
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/13929] [3.4/3.5 Regression] Segfault in convert_nontype_argument with invalid pointer to member
2004-01-30 11:16 [Bug c++/13929] New: [3.4/3.5 Regression] Segfault in convert_nontype_argument with invalid pointer to member giovannibajo at libero dot it
@ 2004-01-30 11:16 ` giovannibajo at libero dot it
2004-01-30 12:32 ` [Bug c++/13929] [3.4 " pinskia at gcc dot gnu dot org
2004-01-30 14:45 ` bangerth at dealii dot org
2 siblings, 0 replies; 4+ messages in thread
From: giovannibajo at libero dot it @ 2004-01-30 11:16 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Known to fail| |3.4.0 3.5.0
Known to work| |3.2.2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13929
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/13929] [3.4 Regression] Segfault in convert_nontype_argument with invalid pointer to member
2004-01-30 11:16 [Bug c++/13929] New: [3.4/3.5 Regression] Segfault in convert_nontype_argument with invalid pointer to member giovannibajo at libero dot it
2004-01-30 11:16 ` [Bug c++/13929] " giovannibajo at libero dot it
@ 2004-01-30 12:32 ` pinskia at gcc dot gnu dot org
2004-01-30 14:45 ` bangerth at dealii dot org
2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-01-30 12:32 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-01-30 12:32 -------
I can confirm it on a mainline build from 20040118 but it is already fixed in 20040129 and
20040127. I think this is also fixed on the 3.4.0 branch but I did not test it.
I almost think it was fixed by:
2004-01-26 Mark Mitchell <mark@codesourcery.com>
* class.c (add_method): Just check processing_template_decl to
determine whether or not we are within a template.
* decl2.c (maybe_retrofit_in_chrg): Likewise.
* init.c (decl_constant_value): Check the type of the declaration,
not TREE_READONLY.
* name-lookup.c (maybe_push_to_top_level): Rename to ...
(push_to_top_level): ... this.
* name-lookup.h (maybe_push_to_top_level): Do not declare it.
* pt.c (push_template_decl_real): Reorder condition for speed.
(convert_template_argument): Use dependency-checking functions in
place of uses_template_parms.
(lookup_template_class): Avoid calling uses_template_parms more
than once.
(uses_template_parms): Reimplement, using dependency-checking
functions.
(instantiate_class_template): Use push_to_top_level, not
maybe_push_to_top_level.
(type_unification_real): Simplify.
(type_dependent_expression_p): Handle OFFSET_REFs and
TEMPLATE_DECLs.
(any_dependent_template_arguments_p): Handle multiple levels of
template argument.
* semantics.c (expand_or_defer_fn): Do not check
uses_template_parms for template instantiations.
* typeck.c (comptypes): Avoid calling cp_type_quals.
--
What |Removed |Added
----------------------------------------------------------------------------
Summary|[3.4/3.5 Regression] |[3.4 Regression] Segfault in
|Segfault in |convert_nontype_argument
|convert_nontype_argument |with invalid pointer to
|with invalid pointer to |member
|member |
Target Milestone|--- |3.4.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13929
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug c++/13929] [3.4 Regression] Segfault in convert_nontype_argument with invalid pointer to member
2004-01-30 11:16 [Bug c++/13929] New: [3.4/3.5 Regression] Segfault in convert_nontype_argument with invalid pointer to member giovannibajo at libero dot it
2004-01-30 11:16 ` [Bug c++/13929] " giovannibajo at libero dot it
2004-01-30 12:32 ` [Bug c++/13929] [3.4 " pinskia at gcc dot gnu dot org
@ 2004-01-30 14:45 ` bangerth at dealii dot org
2 siblings, 0 replies; 4+ messages in thread
From: bangerth at dealii dot org @ 2004-01-30 14:45 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bangerth at dealii dot org 2004-01-30 14:45 -------
This is fixed on both 3.4 and mainline. The bug is still on tree-ssa,
but it will get the fix on the next merge from mainline.
W.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Known to fail|3.4.0 3.5.0 |
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13929
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2004-01-30 14:45 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-30 11:16 [Bug c++/13929] New: [3.4/3.5 Regression] Segfault in convert_nontype_argument with invalid pointer to member giovannibajo at libero dot it
2004-01-30 11:16 ` [Bug c++/13929] " giovannibajo at libero dot it
2004-01-30 12:32 ` [Bug c++/13929] [3.4 " pinskia at gcc dot gnu dot org
2004-01-30 14:45 ` bangerth at dealii dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).