diff --git a/gcc/ada/gcc-interface/decl.cc b/gcc/ada/gcc-interface/decl.cc index 494b24e2111..ee913a017d2 100644 --- a/gcc/ada/gcc-interface/decl.cc +++ b/gcc/ada/gcc-interface/decl.cc @@ -163,17 +163,6 @@ struct GTY((for_user)) tree_entity_vec_map vec *to; }; -void -gt_pch_nx (Entity_Id &) -{ -} - -void -gt_pch_nx (Entity_Id *x, gt_pointer_operator op, void *cookie) -{ - op (x, NULL, cookie); -} - struct dummy_type_hasher : ggc_cache_ptr_hash { static inline hashval_t diff --git a/gcc/vec.h b/gcc/vec.h index 36918915701..6f7b0487eb6 100644 --- a/gcc/vec.h +++ b/gcc/vec.h @@ -1390,6 +1390,13 @@ gt_pch_nx (vec *v) gt_pch_nx ((*v)[i]); } +template +void +gt_pch_nx (vec *) +{ + /* No pointers to note. */ +} + template void gt_pch_nx (vec *v, gt_pointer_operator op, void *cookie) @@ -1407,6 +1414,13 @@ gt_pch_nx (vec *v, gt_pointer_operator op, void *cookie) gt_pch_nx (&((*v)[i]), op, cookie); } +template +void +gt_pch_nx (vec *, gt_pointer_operator, void *) +{ + /* No pointers to note. */ +} + /* Space efficient vector. These vectors can grow dynamically and are allocated together with their control data. They are suited to be @@ -2286,12 +2300,12 @@ public: array_slice (vec &v) : m_base (v.address ()), m_size (v.length ()) {} - template - array_slice (const vec *v) + template + array_slice (const vec *v) : m_base (v ? v->address () : nullptr), m_size (v ? v->length () : 0) {} - template - array_slice (vec *v) + template + array_slice (vec *v) : m_base (v ? v->address () : nullptr), m_size (v ? v->length () : 0) {} iterator begin () { return m_base; }