(data)
| 116 | return newdata |
| 117 | |
| 118 | def check(data): |
| 119 | # Check that all alias definitions from the X11 file |
| 120 | # are actually mapped to the correct alias locales. |
| 121 | errors = 0 |
| 122 | for k, v in data.items(): |
| 123 | if locale.normalize(k) != v: |
| 124 | print('ERROR: %a -> %a != %a' % (k, locale.normalize(k), v), |
| 125 | file=sys.stderr) |
| 126 | errors += 1 |
| 127 | return errors |
| 128 | |
| 129 | if __name__ == '__main__': |
| 130 | import argparse |