Fix availability of MP_ERROR_TEXT in misc.h

This commit is contained in:
Jeff Epler 2023-09-20 11:20:56 -05:00
parent aceb573c88
commit 73612ac119
No known key found for this signature in database
GPG Key ID: D5BF15AB975AB4DE
1 changed files with 3 additions and 1 deletions

View File

@ -341,7 +341,9 @@ typedef const char *mp_rom_error_text_t;
// Might add more types of compressed text in the future.
// For now, forward directly to MP_COMPRESSED_ROM_TEXT.
// CIRCUITPY: MP_ERROR_TEXT() -> translate()
#if !CIRCUITPY
#if CIRCUITPY
#include "supervisor/shared/translate/translate.h"
#else
#define MP_ERROR_TEXT(x) (mp_rom_error_text_t)MP_COMPRESSED_ROM_TEXT(x)
#endif