summaryrefslogtreecommitdiff
path: root/extmod
diff options
context:
space:
mode:
authorDamien George <damien@micropython.org>2022-05-31 22:56:11 +1000
committerDamien George <damien@micropython.org>2022-06-02 16:31:37 +1000
commitefe23aca7154d21a9e8f283313c7a1ac29e05d86 (patch)
tree385afed48501b70d94ac3869901ad6fd809201f8 /extmod
parent47f634300c5572571816817f16836113c98814ae (diff)
all: Remove third argument to MP_REGISTER_MODULE.
It's no longer needed because this macro is now processed after preprocessing the source code via cpp (in the qstr extraction stage), which means unused MP_REGISTER_MODULE's are filtered out by the preprocessor. Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'extmod')
-rw-r--r--extmod/modbluetooth.c2
-rw-r--r--extmod/modbtree.c2
-rw-r--r--extmod/modframebuf.c2
-rw-r--r--extmod/modlwip.c4
-rw-r--r--extmod/modnetwork.c2
-rw-r--r--extmod/modonewire.c2
-rw-r--r--extmod/moduasyncio.c2
-rw-r--r--extmod/modubinascii.c2
-rw-r--r--extmod/moducryptolib.c2
-rw-r--r--extmod/moductypes.c2
-rw-r--r--extmod/moduhashlib.c2
-rw-r--r--extmod/moduheapq.c2
-rw-r--r--extmod/modujson.c2
-rw-r--r--extmod/moduos.c2
-rw-r--r--extmod/moduplatform.c2
-rw-r--r--extmod/modurandom.c2
-rw-r--r--extmod/modure.c2
-rw-r--r--extmod/moduselect.c2
-rw-r--r--extmod/modusocket.c2
-rw-r--r--extmod/modussl_axtls.c2
-rw-r--r--extmod/modussl_mbedtls.c2
-rw-r--r--extmod/modutimeq.c3
-rw-r--r--extmod/moduwebsocket.c2
-rw-r--r--extmod/moduzlib.c2
-rw-r--r--extmod/modwebrepl.c2
25 files changed, 27 insertions, 26 deletions
diff --git a/extmod/modbluetooth.c b/extmod/modbluetooth.c
index aecf48fd4..6bdea1616 100644
--- a/extmod/modbluetooth.c
+++ b/extmod/modbluetooth.c
@@ -1004,7 +1004,7 @@ const mp_obj_module_t mp_module_ubluetooth = {
.globals = (mp_obj_dict_t *)&mp_module_bluetooth_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ubluetooth, mp_module_ubluetooth, MICROPY_PY_BLUETOOTH);
+MP_REGISTER_MODULE(MP_QSTR_ubluetooth, mp_module_ubluetooth);
// Helpers
diff --git a/extmod/modbtree.c b/extmod/modbtree.c
index df33d765e..60a5beec6 100644
--- a/extmod/modbtree.c
+++ b/extmod/modbtree.c
@@ -380,7 +380,7 @@ const mp_obj_module_t mp_module_btree = {
.globals = (mp_obj_dict_t *)&mp_module_btree_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_btree, mp_module_btree, MICROPY_PY_BTREE);
+MP_REGISTER_MODULE(MP_QSTR_btree, mp_module_btree);
#endif
#endif // MICROPY_PY_BTREE
diff --git a/extmod/modframebuf.c b/extmod/modframebuf.c
index 4dfdb7eea..5b6575d5a 100644
--- a/extmod/modframebuf.c
+++ b/extmod/modframebuf.c
@@ -668,7 +668,7 @@ const mp_obj_module_t mp_module_framebuf = {
.globals = (mp_obj_dict_t *)&framebuf_module_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_framebuf, mp_module_framebuf, MICROPY_PY_FRAMEBUF);
+MP_REGISTER_MODULE(MP_QSTR_framebuf, mp_module_framebuf);
#endif
#endif // MICROPY_PY_FRAMEBUF
diff --git a/extmod/modlwip.c b/extmod/modlwip.c
index 47d5bcdbb..ec5f3bfd6 100644
--- a/extmod/modlwip.c
+++ b/extmod/modlwip.c
@@ -1778,9 +1778,9 @@ const mp_obj_module_t mp_module_lwip = {
.globals = (mp_obj_dict_t *)&mp_module_lwip_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_lwip, mp_module_lwip, MICROPY_PY_LWIP);
+MP_REGISTER_MODULE(MP_QSTR_lwip, mp_module_lwip);
// On LWIP-ports, this is the usocket module (replaces extmod/modusocket.c).
-MP_REGISTER_MODULE(MP_QSTR_usocket, mp_module_lwip, MICROPY_PY_LWIP);
+MP_REGISTER_MODULE(MP_QSTR_usocket, mp_module_lwip);
#endif // MICROPY_PY_LWIP
diff --git a/extmod/modnetwork.c b/extmod/modnetwork.c
index f63f708a2..87e155e09 100644
--- a/extmod/modnetwork.c
+++ b/extmod/modnetwork.c
@@ -102,7 +102,7 @@ const mp_obj_module_t mp_module_network = {
.globals = (mp_obj_dict_t *)&mp_module_network_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_network, mp_module_network, MICROPY_PY_NETWORK);
+MP_REGISTER_MODULE(MP_QSTR_network, mp_module_network);
/*******************************************************************************/
// Implementations of network methods that can be used by any interface
diff --git a/extmod/modonewire.c b/extmod/modonewire.c
index 1cfddc830..f440f75a8 100644
--- a/extmod/modonewire.c
+++ b/extmod/modonewire.c
@@ -163,6 +163,6 @@ const mp_obj_module_t mp_module_onewire = {
.globals = (mp_obj_dict_t *)&onewire_module_globals,
};
-MP_REGISTER_MODULE(MP_QSTR__onewire, mp_module_onewire, MICROPY_PY_ONEWIRE);
+MP_REGISTER_MODULE(MP_QSTR__onewire, mp_module_onewire);
#endif // MICROPY_PY_ONEWIRE
diff --git a/extmod/moduasyncio.c b/extmod/moduasyncio.c
index b09b8d67b..6e3603fa1 100644
--- a/extmod/moduasyncio.c
+++ b/extmod/moduasyncio.c
@@ -310,6 +310,6 @@ const mp_obj_module_t mp_module_uasyncio = {
.globals = (mp_obj_dict_t *)&mp_module_uasyncio_globals,
};
-MP_REGISTER_MODULE(MP_QSTR__uasyncio, mp_module_uasyncio, MICROPY_PY_UASYNCIO);
+MP_REGISTER_MODULE(MP_QSTR__uasyncio, mp_module_uasyncio);
#endif // MICROPY_PY_UASYNCIO
diff --git a/extmod/modubinascii.c b/extmod/modubinascii.c
index a362a2d6e..c0e2c587f 100644
--- a/extmod/modubinascii.c
+++ b/extmod/modubinascii.c
@@ -258,6 +258,6 @@ const mp_obj_module_t mp_module_ubinascii = {
.globals = (mp_obj_dict_t *)&mp_module_binascii_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ubinascii, mp_module_ubinascii, MICROPY_PY_UBINASCII);
+MP_REGISTER_MODULE(MP_QSTR_ubinascii, mp_module_ubinascii);
#endif // MICROPY_PY_UBINASCII
diff --git a/extmod/moducryptolib.c b/extmod/moducryptolib.c
index ba04a7bde..c58abaada 100644
--- a/extmod/moducryptolib.c
+++ b/extmod/moducryptolib.c
@@ -374,6 +374,6 @@ const mp_obj_module_t mp_module_ucryptolib = {
.globals = (mp_obj_dict_t *)&mp_module_ucryptolib_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ucryptolib, mp_module_ucryptolib, MICROPY_PY_UCRYPTOLIB);
+MP_REGISTER_MODULE(MP_QSTR_ucryptolib, mp_module_ucryptolib);
#endif // MICROPY_PY_UCRYPTOLIB
diff --git a/extmod/moductypes.c b/extmod/moductypes.c
index a6ebd92eb..547453c48 100644
--- a/extmod/moductypes.c
+++ b/extmod/moductypes.c
@@ -717,6 +717,6 @@ const mp_obj_module_t mp_module_uctypes = {
.globals = (mp_obj_dict_t *)&mp_module_uctypes_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uctypes, mp_module_uctypes, MICROPY_PY_UCTYPES);
+MP_REGISTER_MODULE(MP_QSTR_uctypes, mp_module_uctypes);
#endif
diff --git a/extmod/moduhashlib.c b/extmod/moduhashlib.c
index ded9972ca..39488788f 100644
--- a/extmod/moduhashlib.c
+++ b/extmod/moduhashlib.c
@@ -371,6 +371,6 @@ const mp_obj_module_t mp_module_uhashlib = {
.globals = (mp_obj_dict_t *)&mp_module_uhashlib_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uhashlib, mp_module_uhashlib, MICROPY_PY_UHASHLIB);
+MP_REGISTER_MODULE(MP_QSTR_uhashlib, mp_module_uhashlib);
#endif // MICROPY_PY_UHASHLIB
diff --git a/extmod/moduheapq.c b/extmod/moduheapq.c
index 42871f2c0..bfa6ba608 100644
--- a/extmod/moduheapq.c
+++ b/extmod/moduheapq.c
@@ -118,7 +118,7 @@ const mp_obj_module_t mp_module_uheapq = {
.globals = (mp_obj_dict_t *)&mp_module_uheapq_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uheapq, mp_module_uheapq, MICROPY_PY_UHEAPQ);
+MP_REGISTER_MODULE(MP_QSTR_uheapq, mp_module_uheapq);
#endif
#endif // MICROPY_PY_UHEAPQ
diff --git a/extmod/modujson.c b/extmod/modujson.c
index befa351f1..bee432db2 100644
--- a/extmod/modujson.c
+++ b/extmod/modujson.c
@@ -381,6 +381,6 @@ const mp_obj_module_t mp_module_ujson = {
.globals = (mp_obj_dict_t *)&mp_module_ujson_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ujson, mp_module_ujson, MICROPY_PY_UJSON);
+MP_REGISTER_MODULE(MP_QSTR_ujson, mp_module_ujson);
#endif // MICROPY_PY_UJSON
diff --git a/extmod/moduos.c b/extmod/moduos.c
index 2b902eb21..87a611148 100644
--- a/extmod/moduos.c
+++ b/extmod/moduos.c
@@ -176,6 +176,6 @@ const mp_obj_module_t mp_module_uos = {
.globals = (mp_obj_dict_t *)&os_module_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uos, mp_module_uos, MICROPY_PY_UOS);
+MP_REGISTER_MODULE(MP_QSTR_uos, mp_module_uos);
#endif // MICROPY_PY_UOS
diff --git a/extmod/moduplatform.c b/extmod/moduplatform.c
index 16e45078f..1b35b08aa 100644
--- a/extmod/moduplatform.c
+++ b/extmod/moduplatform.c
@@ -75,6 +75,6 @@ const mp_obj_module_t mp_module_uplatform = {
.globals = (mp_obj_dict_t *)&modplatform_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uplatform, mp_module_uplatform, MICROPY_PY_UPLATFORM);
+MP_REGISTER_MODULE(MP_QSTR_uplatform, mp_module_uplatform);
#endif // MICROPY_PY_UPLATFORM
diff --git a/extmod/modurandom.c b/extmod/modurandom.c
index 6e5f99de7..2e29f7ca6 100644
--- a/extmod/modurandom.c
+++ b/extmod/modurandom.c
@@ -255,7 +255,7 @@ const mp_obj_module_t mp_module_urandom = {
.globals = (mp_obj_dict_t *)&mp_module_urandom_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_urandom, mp_module_urandom, MICROPY_PY_URANDOM);
+MP_REGISTER_MODULE(MP_QSTR_urandom, mp_module_urandom);
#endif
#endif // MICROPY_PY_URANDOM
diff --git a/extmod/modure.c b/extmod/modure.c
index 1d9d82c7b..6bd898984 100644
--- a/extmod/modure.c
+++ b/extmod/modure.c
@@ -448,7 +448,7 @@ const mp_obj_module_t mp_module_ure = {
.globals = (mp_obj_dict_t *)&mp_module_re_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ure, mp_module_ure, MICROPY_PY_URE);
+MP_REGISTER_MODULE(MP_QSTR_ure, mp_module_ure);
#endif
// Source files #include'd here to make sure they're compiled in
diff --git a/extmod/moduselect.c b/extmod/moduselect.c
index 296d38a5d..70a1de2e4 100644
--- a/extmod/moduselect.c
+++ b/extmod/moduselect.c
@@ -373,6 +373,6 @@ const mp_obj_module_t mp_module_uselect = {
.globals = (mp_obj_dict_t *)&mp_module_select_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uselect, mp_module_uselect, MICROPY_PY_USELECT);
+MP_REGISTER_MODULE(MP_QSTR_uselect, mp_module_uselect);
#endif // MICROPY_PY_USELECT
diff --git a/extmod/modusocket.c b/extmod/modusocket.c
index c5db80f37..ebddb1ec7 100644
--- a/extmod/modusocket.c
+++ b/extmod/modusocket.c
@@ -637,6 +637,6 @@ const mp_obj_module_t mp_module_usocket = {
.globals = (mp_obj_dict_t *)&mp_module_usocket_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_usocket, mp_module_usocket, MICROPY_PY_NETWORK && MICROPY_PY_USOCKET && !MICROPY_PY_LWIP);
+MP_REGISTER_MODULE(MP_QSTR_usocket, mp_module_usocket);
#endif // MICROPY_PY_NETWORK && MICROPY_PY_USOCKET && !MICROPY_PY_LWIP
diff --git a/extmod/modussl_axtls.c b/extmod/modussl_axtls.c
index c9ce629b6..9ba613a3e 100644
--- a/extmod/modussl_axtls.c
+++ b/extmod/modussl_axtls.c
@@ -358,6 +358,6 @@ const mp_obj_module_t mp_module_ussl = {
.globals = (mp_obj_dict_t *)&mp_module_ssl_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ussl, mp_module_ussl, MICROPY_PY_USSL && MICROPY_SSL_AXTLS);
+MP_REGISTER_MODULE(MP_QSTR_ussl, mp_module_ussl);
#endif // MICROPY_PY_USSL && MICROPY_SSL_AXTLS
diff --git a/extmod/modussl_mbedtls.c b/extmod/modussl_mbedtls.c
index 8496642d0..0d5d4197c 100644
--- a/extmod/modussl_mbedtls.c
+++ b/extmod/modussl_mbedtls.c
@@ -418,6 +418,6 @@ const mp_obj_module_t mp_module_ussl = {
.globals = (mp_obj_dict_t *)&mp_module_ssl_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_ussl, mp_module_ussl, MICROPY_PY_USSL && MICROPY_SSL_MBEDTLS);
+MP_REGISTER_MODULE(MP_QSTR_ussl, mp_module_ussl);
#endif // MICROPY_PY_USSL && MICROPY_SSL_MBEDTLS
diff --git a/extmod/modutimeq.c b/extmod/modutimeq.c
index 93a9d09b0..1dde90bd1 100644
--- a/extmod/modutimeq.c
+++ b/extmod/modutimeq.c
@@ -229,5 +229,6 @@ const mp_obj_module_t mp_module_utimeq = {
.globals = (mp_obj_dict_t *)&mp_module_utimeq_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_utimeq, mp_module_utimeq, MICROPY_PY_UTIMEQ);
+MP_REGISTER_MODULE(MP_QSTR_utimeq, mp_module_utimeq);
+
#endif // MICROPY_PY_UTIMEQ
diff --git a/extmod/moduwebsocket.c b/extmod/moduwebsocket.c
index 48f4cc78e..a9ad0c22e 100644
--- a/extmod/moduwebsocket.c
+++ b/extmod/moduwebsocket.c
@@ -310,6 +310,6 @@ const mp_obj_module_t mp_module_uwebsocket = {
.globals = (mp_obj_dict_t *)&uwebsocket_module_globals,
};
-MP_REGISTER_MODULE(MP_QSTR_uwebsocket, mp_module_uwebsocket, MICROPY_PY_UWEBSOCKET);
+MP_REGISTER_MODULE(MP_QSTR_uwebsocket, mp_module_uwebsocket);
#endif // MICROPY_PY_UWEBSOCKET
diff --git a/extmod/moduzlib.c b/extmod/moduzlib.c
index b74c6b7b1..0161b9f49 100644
--- a/extmod/moduzlib.c
+++ b/extmod/moduzlib.c
@@ -223,7 +223,7 @@ const mp_obj_module_t mp_module_uzlib = {
};
-MP_REGISTER_MODULE(MP_QSTR_uzlib, mp_module_uzlib, MICROPY_PY_UZLIB);
+MP_REGISTER_MODULE(MP_QSTR_uzlib, mp_module_uzlib);
#endif
// Source files #include'd here to make sure they're compiled in
diff --git a/extmod/modwebrepl.c b/extmod/modwebrepl.c
index e5fa5128c..1a2a718ac 100644
--- a/extmod/modwebrepl.c
+++ b/extmod/modwebrepl.c
@@ -363,6 +363,6 @@ const mp_obj_module_t mp_module_webrepl = {
.globals = (mp_obj_dict_t *)&webrepl_module_globals,
};
-MP_REGISTER_MODULE(MP_QSTR__webrepl, mp_module_webrepl, MICROPY_PY_WEBREPL);
+MP_REGISTER_MODULE(MP_QSTR__webrepl, mp_module_webrepl);
#endif // MICROPY_PY_WEBREPL