mirror of
https://gcc.gnu.org/git/gcc.git
synced 2024-12-04 01:04:26 +08:00
c++: Fix cp_build_function_call_vec [PR 98626]
I misunderstood the cp_build_function_call_vec API, thinking a NULL vector was an acceptable way of passing no arguments. You need to pass a vector of no elements. PR c++/98626 gcc/cp/ * module.cc (module_add_import_initializers): Pass a zero-element argument vector.
This commit is contained in:
parent
264a1269b4
commit
11cbea852b
@ -18977,8 +18977,8 @@ module_add_import_initializers ()
|
|||||||
if (modules)
|
if (modules)
|
||||||
{
|
{
|
||||||
tree fntype = build_function_type (void_type_node, void_list_node);
|
tree fntype = build_function_type (void_type_node, void_list_node);
|
||||||
vec<tree, va_gc> *args = NULL;
|
releasing_vec args; // There are no args
|
||||||
|
|
||||||
for (unsigned ix = modules->length (); --ix;)
|
for (unsigned ix = modules->length (); --ix;)
|
||||||
{
|
{
|
||||||
module_state *import = (*modules)[ix];
|
module_state *import = (*modules)[ix];
|
||||||
|
Loading…
Reference in New Issue
Block a user