Spirik / GEM

Good Enough Menu for Arduino
GNU Lesser General Public License v3.0
245 stars 36 forks source link

Problem with ESP32 S3, When i updated arduino-esp32 and boards #97

Closed motniemtin closed 3 months ago

motniemtin commented 3 months ago
/libraries/GEM/src/GEMItem.cpp: In constructor 'GEMItem::GEMItem(const char*, byte&, GEMSelect&, void (*)(GEMCallbackData))':
/libraries/GEM/src/GEMItem.cpp:96:38: error: either all initializer clauses should be designated or none of them should be
   96 |   , callbackData{ .pMenuItem = this, { 0 } }

My demo Project https://wokwi.com/projects/402474219113695233

image

Spirik commented 3 months ago

Hi! Yep, seems the same issue as #96 . I am unable to reproduce the issue at my local Arduino IDE setup yet, but I haven't updated boards in a while. I assume, some of the latest updates come with an updated compiler (or its settings).

Will look into it closely.

Spirik commented 3 months ago

I was able to reproduce the issue after updating ESP32 boards via Arduino IDE. Will work on the fix next.

motniemtin commented 3 months ago

Hope you update soon

Spirik commented 3 months ago

Now fixed in release 1.5.3.

The issue was due to more strict regulations of designated initializers in recent compilers starting with C++20. And recent update of ESP32 core version 3.0 (that comes with boards update via Arduino IDE) uses C++23.

Wokwi demo compiles successfully now (you may need to remove and re-add GEM library for new version to be fetched):

image
motniemtin commented 3 months ago

Thank you so much !!!