From bf5730d773ea9e7735a997c1fe474f1706a614c5 Mon Sep 17 00:00:00 2001 From: Jason Merrill Date: Wed, 15 Apr 2015 17:17:15 -0400 Subject: [PATCH] * decl2.c (determine_visibility): Use get_template_info. From-SVN: r222133 --- gcc/cp/ChangeLog | 4 ++++ gcc/cp/decl2.c | 4 +--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 3534fdb8b2d..519fc81f812 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2015-04-15 Jason Merrill + + * decl2.c (determine_visibility): Use get_template_info. + 2015-04-15 Jason Merrill Marek Polacek diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index 989a0303bab..5a58d3391c8 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -2386,9 +2386,7 @@ determine_visibility (tree decl) { /* If the specialization doesn't specify visibility, use the visibility from the template. */ - tree tinfo = (TREE_CODE (decl) == TYPE_DECL - ? TYPE_TEMPLATE_INFO (TREE_TYPE (decl)) - : DECL_TEMPLATE_INFO (decl)); + tree tinfo = get_template_info (decl); tree args = TI_ARGS (tinfo); tree attribs = (TREE_CODE (decl) == TYPE_DECL ? TYPE_ATTRIBUTES (TREE_TYPE (decl)) -- 2.30.2