Hi,
I was following the ble application guide and got the below error message.
I tried ignoring the error by commenting out some lines but next up another
similar error popped up..!
Anyone has idea what could be wrong?
Error: repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c: In
function 'value_to_pretty':
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:305:50: error:
"/*" within comment [-Werror=comment]
305 | cbor_value_get_raw_integer(it, &val); /* can't fail */
|
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:308:33: error:
expected ')' before 'PRIu64'
308 | if (fprintf(out, "%" PRIu64, val) < 0)
| ^~~~~~~
| )
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:308:31: error:
spurious trailing '%' in format [-Werror=format=]
308 | if (fprintf(out, "%" PRIu64, val) < 0)
| ^
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:313:19: error:
'val' undeclared (first use in this function)
313 | if (++val) { /* unsigned overflow may
happen */
| ^~~
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:313:19: note:
each undeclared identifier is reported only once for each function it
appears in
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:314:38: error:
expected ')' before 'PRIu64'
314 | if (fprintf(out, "-%" PRIu64, val) < 0)
| ^~~~~~~
| )
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:314:36: error:
spurious trailing '%' in format [-Werror=format=]
314 | if (fprintf(out, "-%" PRIu64, val) < 0)
| ^
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:323:11: error:
expected expression before '/' token
323 | }*/
| ^
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:358:29: error:
expected ')' before 'PRIu64'
358 | if (fprintf(out, "%" PRIu64 "(", tag) < 0)
| ^~~~~~~
| )
repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:358:27: error:
spurious trailing '%' in format [-Werror=format=]
358 | if (fprintf(out, "%" PRIu64 "(", tag) < 0)
| ^
cc1: all warnings being treated as errors
Regards,
Ujjval