Hello,
So I’m a newbie to PlatformIO but I’ve had no problems with it besides this ‘clang-diagnostic error’ I get when using the IDE in vscode.
These are the error I’m getting:
cstdlib(144, 11): no member named 'calloc' in the global namespace
cstdlib(151, 11): no member named 'malloc' in the global namespace
cstdlib(164, 11): no member named 'realloc' in the global namespace; did you mean 'reallocf'?
stdlib.h(148, 7): 'reallocf' declared here
new(89, 14): enumeration redeclared with different underlying type 'size_t' (aka 'unsigned int') (was 'unsigned long long')
new(126, 26): 'operator new' takes type size_t ('unsigned long long') as first parameter
new(128, 26): 'operator new[]' takes type size_t ('unsigned long long') as first parameter
new(140, 26): 'operator new' takes type size_t ('unsigned long long') as first parameter
new(142, 26): 'operator new[]' takes type size_t ('unsigned long long') as first parameter
new(149, 57): no type named 'align_val_t' in namespace 'std'
new(151, 57): no type named 'align_val_t' in namespace 'std'
new(153, 34): no type named 'align_val_t' in namespace 'std'
stdlib.h(59, 12): no member named 'calloc' in namespace 'std'
stdlib.h(65, 12): no member named 'malloc' in namespace 'std'
stdlib.h(73, 12): no member named 'realloc' in namespace 'std'; did you mean 'reallocf'?
cstdlib(164, 11): 'reallocf' declared here
stdlib.h(91, 27): expected function body after function declarator
_ansi.h(27, 18): expanded from macro '_NOTHROW'
stdlib.h(108, 71): expected function body after function declarator
_ansi.h(27, 18): expanded from macro '_NOTHROW'
stdlib.h(145, 66): expected function body after function declarator
_ansi.h(27, 18): expanded from macro '_NOTHROW'
stddef.h(209, 23): typedef redefinition with different types ('unsigned int' vs 'unsigned long long')
The program itself has no errors, it compiles and uploads just fine and does exactly what’s expected. I’m just confused as to how to get rid of these errors.
If needed, this is my platformio.ini:
[env:teensy40]
platform = teensy
board = teensy40
framework = arduino
lib_deps =
sparkfun/SX1509 IO Expander@^3.0.5
pololu/VL53L0X@^1.3.1
pololu/VL53L1X@^1.3.1
Wire@^1.0
Any help would be mighty appreciated.