Don't try to print the vector size if it is empty (a single bit)

This commit is contained in:
Cary R 2014-08-27 17:53:20 -07:00
parent 3852545f21
commit 931039761a
1 changed files with 5 additions and 3 deletions

View File

@ -187,9 +187,11 @@ void uarray_type_t::pform_dump(ostream&out, unsigned indent) const
void vector_type_t::pform_dump(ostream&fd, unsigned indent) const
{
fd << setw(indent) << "" << "vector of " << base_type;
for (list<pform_range_t>::iterator cur = pdims->begin()
; cur != pdims->end() ; ++cur) {
fd << "[" << *(cur->first) << ":" << *(cur->second) << "]";
if (pdims.get()) {
for (list<pform_range_t>::iterator cur = pdims->begin()
; cur != pdims->end() ; ++cur) {
fd << "[" << *(cur->first) << ":" << *(cur->second) << "]";
}
}
fd << endl;
}