diff options
| author | Jeff Epler <jepler@gmail.com> | 2020-08-01 12:14:55 -0500 |
|---|---|---|
| committer | Jeff Epler <jepler@gmail.com> | 2020-08-04 13:34:29 -0500 |
| commit | dddd25a776fb0d9c002c1b6b039e24bb3048e6ff (patch) | |
| tree | 72406398044fe8064b7e43fcd3c8e16f7a86b6f5 /shared-bindings/ps2io | |
| parent | c394af412837f96164ebcc88d5301bece19e4a6f (diff) | |
Combine similar strings to reduce size of translations
This is a slight trade-off with code size, in places where a "_varg"
mp_raise variant is now used. The net savings on trinket_m0 is
just 32 bytes.
It also means that the translation will include the original English
text, and cannot be translated. These are usually names of Python
types such as int, set, or dict or special values such as "inf" or
"Nan".
Diffstat (limited to 'shared-bindings/ps2io')
| -rw-r--r-- | shared-bindings/ps2io/Ps2.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/shared-bindings/ps2io/Ps2.c b/shared-bindings/ps2io/Ps2.c index 15731ea40..64d93f6ad 100644 --- a/shared-bindings/ps2io/Ps2.c +++ b/shared-bindings/ps2io/Ps2.c @@ -133,7 +133,7 @@ STATIC mp_obj_t ps2io_ps2_obj_popleft(mp_obj_t self_in) { int b = common_hal_ps2io_ps2_popleft(self); if (b < 0) { - mp_raise_IndexError(translate("Pop from an empty Ps2 buffer")); + mp_raise_IndexError_varg(translate("pop from empty %s"), "Ps2 buffer"); } return MP_OBJ_NEW_SMALL_INT(b); } |
