| 119 | return 'Sum({0.types})'.format(self) |
| 120 | |
| 121 | class Product(AST): |
| 122 | def __init__(self, fields, attributes=None): |
| 123 | self.fields = fields |
| 124 | self.attributes = attributes or [] |
| 125 | |
| 126 | def __repr__(self): |
| 127 | if self.attributes: |
| 128 | return 'Product({0.fields}, {0.attributes})'.format(self) |
| 129 | else: |
| 130 | return 'Product({0.fields})'.format(self) |
| 131 | |
| 132 | # A generic visitor for the meta-AST that describes ASDL. This can be used by |
| 133 | # emitters. Note that this visitor does not provide a generic visit method, so a |
no outgoing calls
no test coverage detected
searching dependent graphs…