From: Jason Merrill Date: Wed, 15 Apr 2015 21:17:15 +0000 (-0400) Subject: * decl2.c (determine_visibility): Use get_template_info. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=bf5730d773ea9e7735a997c1fe474f1706a614c5;p=gcc.git * decl2.c (determine_visibility): Use get_template_info. From-SVN: r222133 --- 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))