diff options
| author | Scott Shawcroft <scott@tannewt.org> | 2018-07-31 16:53:54 -0700 |
|---|---|---|
| committer | Scott Shawcroft <scott@tannewt.org> | 2018-08-07 14:58:57 -0700 |
| commit | 933add6cd833bb6ba6682ad2b6eb478871415ff5 (patch) | |
| tree | 8cb5ee1feb0516c24ee270fcee5ed00d310aced8 /shared-bindings/microcontroller/Pin.c | |
| parent | 2029c4e87e3e71ada07c8be91fe6877edf4a606b (diff) | |
Support internationalisation.
Diffstat (limited to 'shared-bindings/microcontroller/Pin.c')
| -rw-r--r-- | shared-bindings/microcontroller/Pin.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/shared-bindings/microcontroller/Pin.c b/shared-bindings/microcontroller/Pin.c index c456a030f..7ed95ba3b 100644 --- a/shared-bindings/microcontroller/Pin.c +++ b/shared-bindings/microcontroller/Pin.c @@ -31,6 +31,7 @@ #include "py/nlr.h" #include "py/obj.h" #include "py/runtime.h" +#include "supervisor/shared/translate.h" //| .. currentmodule:: microcontroller //| @@ -85,7 +86,7 @@ const mp_obj_type_t mcu_pin_type = { void assert_pin(mp_obj_t obj, bool none_ok) { if ((obj != mp_const_none || !none_ok) && !MP_OBJ_IS_TYPE(obj, &mcu_pin_type)) { - mp_raise_TypeError_varg("Expected a %q", mcu_pin_type.name); + mp_raise_TypeError_varg(translate("Expected a %q"), mcu_pin_type.name); } } |
