[Bug report] nrf cloud headers not working for C++

Hi,

I want to report a bug/issue with the NCS, is this the right place to do that?

We are compiling for C++, so when including headers like <net/nrf_cloud_coap.h> and <net/nrf_cloud_fota_poll.h>
there are some issues.

1. In net/nrf_cloud_fota_poll.h, the curly bracket of 
#ifdef __cplusplus
extern "C" {
#endif
is not closed in the end of the file.
2. In net/nrf_cloud_coap.h, there is an issue with having 
#ifdef __cplusplus
extern "C" {
#endif
before the #includes.
In the first case, it is possible to come around by adding a closing curling bracket after including the header.
In the second case, it is possible to come around by including these three in this exact order:
#include <zephyr/sys/cbprintf.h>
#include <zephyr/sys/cbprintf_cxx.h>
#include <net/nrf_cloud_coap.h>
Even if it's possible to come around, I wanted to report the bugs. Maybe there are some more, so it could be useful to compile for C++ in your tests perhaps.
Parents Reply Children
Related