| 133 | |
| 134 | |
| 135 | class RetValue(object): |
| 136 | |
| 137 | def __init__(self, type): |
| 138 | try: |
| 139 | self.buffer = (TYPES[type] * 1)() |
| 140 | except KeyError: |
| 141 | raise KeyError('The type {} is not defined ()'.format(type, TYPES.keys())) |
| 142 | |
| 143 | def __iter__(self): |
| 144 | yield self |
| 145 | |
| 146 | @property |
| 147 | def value(self): |
| 148 | return self.buffer[0] |
| 149 | |
| 150 | |
| 151 | class RetTuple(object): |
no outgoing calls