def _stringify(self, transform: StringifyTransform) -> str:
    res = []
    l = transform(self.leftSpecs)
    if (len(l) > 0):
        res.append(l)
    if self.trailingTypeSpec:
        if (len(res) > 0):
            res.append(' ')
        res.append(transform(self.trailingTypeSpec))
        r = str(self.rightSpecs)
        if (len(r) > 0):
            if (len(res) > 0):
                res.append(' ')
            res.append(r)
    return ''.join(res)
def _stringify(self, transform: StringifyTransform) -> str:
    res = []
    l = transform(self.leftSpecs)
    if (len(l) > 0):
        res.append(l)
    if self.trailingTypeSpec:
        if (len(res) > 0):
            res.append(' ')
        res.append(transform(self.trailingTypeSpec))
        r = str(self.rightSpecs)
        if (len(r) > 0):
            if (len(res) > 0):
                res.append(' ')
            res.append(r)
    return .join(res)