aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/semantics.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/semantics.c')
-rw-r--r--gcc/cp/semantics.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c
index 3669b24..3b88f15 100644
--- a/gcc/cp/semantics.c
+++ b/gcc/cp/semantics.c
@@ -734,6 +734,9 @@ is_std_constant_evaluated_p (tree fn)
return false;
tree fndecl = cp_get_callee_fndecl_nofold (fn);
+ if (fndecl == NULL_TREE)
+ return false;
+
if (fndecl_built_in_p (fndecl, CP_BUILT_IN_IS_CONSTANT_EVALUATED,
BUILT_IN_FRONTEND))
return true;