def checkAliasValidity(self):
    if (self.alias != None):
        if (len(self.values) != len(self.alias.values)):
            raise Exception(('%s has different number of flags than its alias %s.' % (self.name, self.alias.name)))
        for (index, value) in enumerate(self.values):
            aliasVal = self.alias.values[index]
            if ((value[1] != aliasVal[1]) or (not (value[0].startswith(aliasVal[0]) or aliasVal[0].startswith(value[0])))):
                raise Exception(('Flag %s of %s has different value than %s of %s.' % (self.alias.values[index], self.alias.name, value, self.name)))
def checkAliasValidity(self):
    if (self.alias != None):
        if (len(self.values) != len(self.alias.values)):
            raise Exception(('%s has different number of flags than its alias %s.' % (self.name, self.alias.name)))
        for (index, value) in enumerate(self.values):
            aliasVal = self.alias.values[index]
            if ((value[1] != aliasVal[1]) or (not (value[0].startswith(aliasVal[0]) or aliasVal[0].startswith(value[0])))):
                raise Exception(('Flag %s of %s has different value than %s of %s.' % (self.alias.values[index], self.alias.name, value, self.name)))