Commit 415dcf96 by Jason Merrill Committed by Jason Merrill

pt.c (dependent_type_p): Make sure we aren't called with global_type_node.

	* pt.c (dependent_type_p): Make sure we aren't called with
	global_type_node.

From-SVN: r247843
parent 0ea37ae1
2017-05-10 Jason Merrill <jason@redhat.com> 2017-05-10 Jason Merrill <jason@redhat.com>
* pt.c (dependent_type_p): Make sure we aren't called with
global_type_node.
PR c++/79549 - C++17 ICE with non-type auto template parameter pack PR c++/79549 - C++17 ICE with non-type auto template parameter pack
* pt.c (convert_template_argument): Just return an argument pack. * pt.c (convert_template_argument): Just return an argument pack.
(coerce_template_parameter_pack, template_parm_to_arg) (coerce_template_parameter_pack, template_parm_to_arg)
......
...@@ -23436,6 +23436,10 @@ dependent_type_p (tree type) ...@@ -23436,6 +23436,10 @@ dependent_type_p (tree type)
if (type == error_mark_node) if (type == error_mark_node)
return false; return false;
/* Getting here with global_type_node means we improperly called this
function on the TREE_TYPE of an IDENTIFIER_NODE. */
gcc_checking_assert (type != global_type_node);
/* If we have not already computed the appropriate value for TYPE, /* If we have not already computed the appropriate value for TYPE,
do so now. */ do so now. */
if (!TYPE_DEPENDENT_P_VALID (type)) if (!TYPE_DEPENDENT_P_VALID (type))
......
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