Hrs3300: fix includes for std::begin/std::end
Some checks failed
CI / build-firmware (push) Successful in 5m35s
CI / build-simulator (push) Failing after 2s
CI / get-base-ref-size (push) Has been skipped
CI / Compare build size (push) Has been skipped

Fix for Hrs3300 PR about Atomic HRS reads:
https://github.com/InfiniTimeOrg/InfiniTime/pull/1845

We use `std::begin` and `std::end`, but we don't include one of the
headers that define those functions.
See https://en.cppreference.com/w/cpp/iterator/begin for a list of
headers that define `std::begin` and `std::end`.

Starting with GCC 14 this leads to a compilation error presumably
because they cleaned up their headers.

Fix code by inlcuding `<iterator>`
This commit is contained in:
Reinhold Gschweicher 2024-09-22 11:28:04 +02:00 committed by FintasticMan
parent ad3bf49c7b
commit 997e4cee8c

View file

@ -6,6 +6,7 @@
#include "drivers/Hrs3300.h"
#include <algorithm>
#include <iterator>
#include <nrf_gpio.h>
#include <FreeRTOS.h>