File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change 1010
1111// Platform-specific string storage and return type
1212#ifdef ARDUINO_ARCH_ESP8266
13- // On ESP8266, use PROGMEM storage and return __FlashStringHelper*
14- #include < pgmspace.h>
15- #define DECLARE_STR (name, value ) static const char name##_PROGMEM[] PROGMEM = value
16- #define STR (name ) (reinterpret_cast <const __FlashStringHelper*>(name##_PROGMEM))
17- #define STR_RETURN_TYPE const __FlashStringHelper*
13+ // On ESP8266, use PROGMEM storage and return __FlashStringHelper*
14+ #include < pgmspace.h>
15+ #define DECLARE_STR (name, value ) static const char name##_PROGMEM[] PROGMEM = value
16+ #define STR (name ) (reinterpret_cast <const __FlashStringHelper *>(name##_PROGMEM))
17+ #define STR_RETURN_TYPE const __FlashStringHelper *
1818#else
19- // On other platforms, use regular constexpr for compile-time optimization
20- #define DECLARE_STR (name, value ) static constexpr const char *name = value
21- #define STR (name ) name
22- #define STR_RETURN_TYPE const char *
19+ // On other platforms, use regular constexpr for compile-time optimization
20+ #define DECLARE_STR (name, value ) static constexpr const char *name = value
21+ #define STR (name ) name
22+ #define STR_RETURN_TYPE const char *
2323#endif
2424
2525namespace asyncsrv {
You can’t perform that action at this time.
0 commit comments