arduino_bootstrapper icon indicating copy to clipboard operation
arduino_bootstrapper copied to clipboard

Name conflict with other libraries for const String ERROR

Open Pronoe opened this issue 3 years ago • 3 comments

Bootstrapper library uses a const STRING ERROR which is a very common name (définitions in Helpers.h, set value in Helspers.cpp, used in BootstrapManager.cpp and may be in the application code). I am using also the ezTime library which use the same name ERROR in an enum list. The compiler raises an error related to the reuse of an existing name, and this, whatever is the order of the #include directives of the 2 libraries. I solved provisionally this issue by renaming ERROR in the Bootstrapper library but this make testing of the committed modifications more difficult. I have now taken the option to modify the ERROR name in the ezTime library. In both case, this is not clean. Could you recommend a better solution as using namespace or anything else ?

Pronoe avatar Mar 11 '22 22:03 Pronoe

yes a namespace would be the best way to do it...

sblantipodi avatar Mar 16 '22 21:03 sblantipodi

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days

github-actions[bot] avatar Apr 16 '22 00:04 github-actions[bot]

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days

github-actions[bot] avatar May 22 '22 00:05 github-actions[bot]