commit 8860243111f961b8f1d37238cd28ed82516b1927
Author: Jason Merrill <jason@redhat.com>
Date: Tue Jan 24 22:05:52 2012 -0500
PR c++/51917
* decl.c (xref_basetypes): Check VEC_length instead of VEC_space.
@@ -11916,8 +11916,8 @@ xref_basetypes (tree ref, tree base_list)
BINFO_BASE_ACCESS_APPEND (binfo, access);
}
- if (VEC_space (tree, CLASSTYPE_VBASECLASSES (ref), 1))
- /* If we have space in the vbase vector, we must have shared at
+ if (VEC_length (tree, CLASSTYPE_VBASECLASSES (ref)) < max_vbases)
+ /* If we didn't get max_vbases vbases, we must have shared at
least one of them, and are therefore diamond shaped. */
CLASSTYPE_DIAMOND_SHAPED_P (ref) = 1;