aboutsummaryrefslogtreecommitdiff
path: root/extmod/modure.c
diff options
context:
space:
mode:
authorJim Mussared <jim.mussared@gmail.com>2020-03-02 22:35:22 +1100
committerDamien George <damien.p.george@gmail.com>2020-04-05 15:02:06 +1000
commitdef76fe4d9bbc2c342594dc05861b24d7165d274 (patch)
treed04ad778e2421de0a85835227ba5bcb08562ec24 /extmod/modure.c
parent85858e72dfdc3e941c2e620e94de05ad663138b1 (diff)
all: Use MP_ERROR_TEXT for all error messages.
Diffstat (limited to 'extmod/modure.c')
-rw-r--r--extmod/modure.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/extmod/modure.c b/extmod/modure.c
index 4f11de5fc..ed16955ae 100644
--- a/extmod/modure.c
+++ b/extmod/modure.c
@@ -235,7 +235,7 @@ STATIC mp_obj_t re_split(size_t n_args, const mp_obj_t *args) {
mp_obj_t s = mp_obj_new_str_of_type(str_type, (const byte *)subj.begin, caps[0] - subj.begin);
mp_obj_list_append(retval, s);
if (self->re.sub > 0) {
- mp_raise_NotImplementedError("Splitting with sub-captures");
+ mp_raise_NotImplementedError(MP_ERROR_TEXT("Splitting with sub-captures"));
}
subj.begin = caps[1];
if (maxsplit > 0 && --maxsplit == 0) {
@@ -403,7 +403,7 @@ STATIC mp_obj_t mod_re_compile(size_t n_args, const mp_obj_t *args) {
int error = re1_5_compilecode(&o->re, re_str);
if (error != 0) {
error:
- mp_raise_ValueError("Error in regex");
+ mp_raise_ValueError(MP_ERROR_TEXT("Error in regex"));
}
#if MICROPY_PY_URE_DEBUG
if (flags & FLAG_DEBUG) {