diff options
author | Gabriel Dos Reis <gdr@integrable-solutions.net> | 2004-08-01 18:07:32 +0000 |
---|---|---|
committer | Gabriel Dos Reis <gdr@gcc.gnu.org> | 2004-08-01 18:07:32 +0000 |
commit | ea0ad329208eaed8bcaa330f81ba4c45527a9ad1 (patch) | |
tree | dbf49b5a482592d5948d69ae31f802c4701226e6 /gcc | |
parent | dc6d70957c4e77512a6f02ec232f14621d7b2f98 (diff) | |
download | gcc-ea0ad329208eaed8bcaa330f81ba4c45527a9ad1.zip gcc-ea0ad329208eaed8bcaa330f81ba4c45527a9ad1.tar.gz gcc-ea0ad329208eaed8bcaa330f81ba4c45527a9ad1.tar.bz2 |
call.c (z_candidate::template_decl): Rename from template.
* call.c (z_candidate::template_decl): Rename from template.
(add_template_candidate_real): Adjust member reference.
(joust): Likewise.
From-SVN: r85411
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/cp/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/cp/call.c | 15 |
2 files changed, 14 insertions, 7 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index d87584e..6122d57 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,9 @@ +2004-08-01 Gabriel Dos Reis <gdr@integrable-solutions.net> + + * call.c (z_candidate::template_decl): Rename from template. + (add_template_candidate_real): Adjust member reference. + (joust): Likewise. + 2004-07-29 Mark Mitchell <mark@codesourcery.com> * cp-tree.h (IDENTIFIER_REPO_CHOSEN): Define. diff --git a/gcc/cp/call.c b/gcc/cp/call.c index 0e734b8..a6bfc72 100644 --- a/gcc/cp/call.c +++ b/gcc/cp/call.c @@ -424,7 +424,7 @@ struct z_candidate { the `this' pointer must correspond to the most derived class indicated by the CONVERSION_PATH. */ tree conversion_path; - tree template; + tree template_decl; candidate_warning *warnings; z_candidate *next; }; @@ -2262,9 +2262,9 @@ add_template_candidate_real (struct z_candidate **candidates, tree tmpl, for this will point at template <class T> template <> S<T>::f(int), so that we can find the definition. For the purposes of overload resolution, however, we want the original TMPL. */ - cand->template = tree_cons (tmpl, targs, NULL_TREE); + cand->template_decl = tree_cons (tmpl, targs, NULL_TREE); else - cand->template = DECL_TEMPLATE_INFO (fn); + cand->template_decl = DECL_TEMPLATE_INFO (fn); return cand; } @@ -6023,9 +6023,9 @@ joust (struct z_candidate *cand1, struct z_candidate *cand2, bool warn) F1 is a non-template function and F2 is a template function specialization. */ - if (! cand1->template && cand2->template) + if (!cand1->template_decl && cand2->template_decl) return 1; - else if (cand1->template && ! cand2->template) + else if (cand1->template_decl && !cand2->template_decl) return -1; /* or, if not that, @@ -6033,10 +6033,11 @@ joust (struct z_candidate *cand1, struct z_candidate *cand2, bool warn) more specialized than the template for F2 according to the partial ordering rules. */ - if (cand1->template && cand2->template) + if (cand1->template_decl && cand2->template_decl) { winner = more_specialized - (TI_TEMPLATE (cand1->template), TI_TEMPLATE (cand2->template), + (TI_TEMPLATE (cand1->template_decl), + TI_TEMPLATE (cand2->template_decl), DEDUCE_ORDER, /* Tell the deduction code how many real function arguments we saw, not counting the implicit 'this' argument. But, |