don't add an empty suboption description

--HG--
extra : convert_revision : 594744c3d438aed08a23db376959930071b2c368
This commit is contained in:
Nathan Binkert 2006-02-23 00:21:35 -05:00
parent 35094fb0fe
commit f462266b30

View file

@ -277,10 +277,11 @@ class Option(Data):
return name
if attr == 'desc':
desc = self.__dict__[attr]
if self._suboption is not None:
desc = '%s, %s' % (desc, self._suboption.desc)
return desc
desc = [ self.__dict__[attr] ]
if self._suboption is not None and self._suboption.desc:
desc.append(self._suboption.desc)
return ', '.join(desc)
return super(Option, self).__getattribute__(attr)