Commit ee00eaea by Andrew Sutton Committed by Jason Merrill

pt.c (type_dependent_expression_p): Handle expressions that refer to variable templates.

	* pt.c (type_dependent_expression_p): Handle expressions
	that refer to variable templates.

From-SVN: r225361
parent 5209ef3c
2015-07-02 Andrew Sutton <andrew.n.sutton@gmail.com>
* pt.c (type_dependent_expression_p): Handle expressions
that refer to variable templates.
2015-07-01 Jason Merrill <jason@redhat.com>
* lex.c (init_reswords): s/CXX0X/CXX11/.
......
......@@ -21606,6 +21606,10 @@ type_dependent_expression_p (tree expression)
return true;
expression = TREE_OPERAND (expression, 0);
}
if (variable_template_p (expression))
return dependent_type_p (TREE_TYPE (expression));
gcc_assert (TREE_CODE (expression) == OVERLOAD
|| TREE_CODE (expression) == FUNCTION_DECL);
......
// { dg-do compile { target c++14 } }
template<typename T>
bool V1 = true;
template<typename T>
bool V1<int> = false; // { dg-error "primary template" }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment