Repository navigation
Description
Summary
Since 3.10.7, every RISC-V build (ESP32-C3 / ESP32-C6) fails to compile with has a different exception specifier errors, because the new riscv.cpp.hpp defines the RISC-V interrupt helpers without FL_NO_EXCEPT while their declarations in riscv.hpp still carry it (noexcept on ESP platforms). Still present in 3.10.8 and on current master.
Environment
- FastLED 3.10.7 and 3.10.8 (3.10.3 is fine)
- arduino-esp32 core 3.2.1 (also unrelated to core version — the mismatch is intra-library)
- ESP32-C6 (
--fqbn esp32:esp32:esp32c6), Arduino CLI - Any sketch that instantiates a clockless driver on a RISC-V target, e.g.
FastLED.addLeds<WS2812, DATA_PIN, GRB>(leds, NUM_LEDS);
Errors
FastLED/src/platforms/esp/32/interrupts/riscv.cpp.hpp:40:11: error: declaration of 'esp_err_t fastled_riscv_install_interrupt(int, int, void (*)(void*), void*, intr_handle_data_t**)' has a different exception specifier
riscv.cpp.hpp:91:11: fastled_riscv_install_official_interrupt(...) ... different exception specifier
riscv.cpp.hpp:107:11: fastled_riscv_install_experimental_interrupt(...) ... different exception specifier
riscv.cpp.hpp:142:14: fastled_riscv_official_handler(void*) ... different exception specifier
riscv.cpp.hpp:151:14: fastled_riscv_experimental_handler(void*) ... different exception specifier
riscv.cpp.hpp:165:11: fastled_riscv_rmt_init_official(...) ... different exception specifier
riscv.cpp.hpp:187:11: fastled_riscv_rmt_init_experimental(...) ... different exception specifier
riscv.cpp.hpp:217:14: fastled_riscv_rmt_official_handler(void*) ... different exception specifier
riscv.cpp.hpp:225:14: fastled_riscv_rmt_experimental_handler(void*) ... different exception specifier
Full log from a public CI failure: https://github.com/Seeed-Studio/xiao-esphome-projects/actions/runs/39352349075 (job "Building Zigbee Arduino IOT_BUTTON_V1").
Analysis
Declarations in src/platforms/esp/32/interrupts/riscv.hpp (3.10.8):
esp_err_t fastled_riscv_install_interrupt(
int source, int priority, void (*handler)(void *), void *arg, intr_handle_t *handle
) FL_NO_EXCEPT; // -> noexcept (fl/stl/noexcept.h, FL_IS_ESP)Definitions in src/platforms/esp/32/interrupts/riscv.cpp.hpp (new file introduced in the post-3.10.6 reshuffle):
esp_err_t fastled_riscv_install_interrupt(
int source, int priority, void (*handler)(void *), void *arg, intr_handle_t *handle
) { // no FL_NO_EXCEPTSame translation unit → GCC rejects the mismatched exception specification. All nine flagged functions follow this pattern. Xtensa targets don't compile this file, which is why only C3/C6 are affected.
Workaround we currently use
The documented external override in fl/stl/noexcept.h:
#define FL_NO_EXCEPT // empty override: matches the definitions as shipped
#include <FastLED.h>Suggested fix
Add FL_NO_EXCEPT to the nine definitions in riscv.cpp.hpp (or drop it from the declarations — but the functions call IDF APIs and are intended non-throwing, so decorating the definitions seems right).
Thanks!
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
zackees commentedon Oct 20, 2026
thanks, we'll get the same
baorepo commentedon Oct 20, 2026
Follow-up worth noting for anyone hitting this: a sketch-level
#define FL_NO_EXCEPTbefore#include <FastLED.h>does not work around it, because the mismatch is compiled inside FastLED's own unity-build unit —src/fl/build/platforms+.cpp→src/platforms/_build.cpp.hpp→src/platforms/esp/_build.cpp.hpp→src/platforms/esp/32/_build.cpp.hpp→riscv.cpp.hpp— which is a separate translation unit that never sees the sketch's macros.The workaround that does work (verified on FastLED 3.10.8 / arduino-esp32 3.2.1 / ESP32-C6: without the flag the sketch fails with the same nine errors, with it the build links cleanly) is injecting the empty override for every compilation unit from the compile command line:
arduino-cli compile --fqbn esp32:esp32:esp32c6:... \ --build-property "build.extra_flags=-DFL_NO_EXCEPT= ..."(-D with an empty value keeps
#ifndef FL_NO_EXCEPTin fl/stl/noexcept.h from re-defining it, so the documented external-override path is respected in all units, including the unity build.)