(t, precision=4)
| 121 | return enc2uni |
| 122 | |
| 123 | def hexrepr(t, precision=4): |
| 124 | |
| 125 | if t is None: |
| 126 | return 'None' |
| 127 | try: |
| 128 | len(t) |
| 129 | except TypeError: |
| 130 | return '0x%0*X' % (precision, t) |
| 131 | try: |
| 132 | return '(' + ', '.join(['0x%0*X' % (precision, item) |
| 133 | for item in t]) + ')' |
| 134 | except TypeError as why: |
| 135 | print('* failed to convert %r: %s' % (t, why)) |
| 136 | raise |
| 137 | |
| 138 | def python_mapdef_code(varname, map, comments=1, precisions=(2, 4)): |
| 139 |
no test coverage detected
searching dependent graphs…