Unused Variable 'target' Warning when Compiling

What do you want to achieve?

My ui.c contains lv_obj_t * target = lv_event_get_target(e); in 147 places which is not used for anything. This generates warning: unused variable 'target' [-Wunused-variable] 147 times since it is not used.

Why is this line of code being generated if it is not used?

Screenshot or video

Here is one example:
image

Others

  • **SquareLine Studio version: 1.3.1
  • **Operating system: Windows 10 x64
  • **Target hardware: ESP32-S3, ESP-IDF 5.1, LVGL 8.3.6

Just a +1, this exists for me as well. Warnings like this cause lots of noise in the build log.

Thanks for the report, we added it to our todo list.