Megunolink / MLP

Arduino library for sending data to MegunoLink visualisers and useful components
http://www.megunolink.com
GNU Lesser General Public License v3.0
46 stars 26 forks source link

Compile issue when using version 1.42 with EasyButton library #15

Open jomoengineer opened 6 days ago

jomoengineer commented 6 days ago

I am going though a ESP32 course with Tech Explorations and part of their code is using the EasyButton library version 2.0.3 which has a dependency of MegunoLink. However, when using version 1.42 of MegunoLink, the code fails to compile. With version 1.41 of MegunoLink, the code compiles and runs without issue.

The error is seen below:

In file included from c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.cpp:1:
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:61:10: error: 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, long unsigned int&)' cannot be overloaded with 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, uint32_t&)'
   61 |     bool AddVariable(const __FlashStringHelper* pName, unsigned long& rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:50:10: note: previous declaration 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, uint32_t&)'
   50 |     bool AddVariable(const __FlashStringHelper *pName, uint32_t &rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:62:10: error: 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, long int&)' cannot be overloaded with 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, int32_t&)'
   62 |     bool AddVariable(const __FlashStringHelper* pName, long& rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:53:10: note: previous declaration 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, int32_t&)'
   53 |     bool AddVariable(const __FlashStringHelper *pName, int32_t &rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.cpp:57:6: error: redefinition of 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, long unsigned int&)'
   57 | bool CommandDispatcherBase::AddVariable(const __FlashStringHelper* pName, unsigned long& rVariable)
      |      ^~~~~~~~~~~~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.cpp:51:6: note: 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, uint32_t&)' previously defined here
   51 | bool CommandDispatcherBase::AddVariable(const __FlashStringHelper *pName, uint32_t &rVariable)
      |      ^~~~~~~~~~~~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.cpp:78:6: error: redefinition of 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, int32_t&)'
   78 | bool CommandDispatcherBase::AddVariable(const __FlashStringHelper *pName, int32_t &rVariable)
      |      ^~~~~~~~~~~~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.cpp:62:6: note: 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, long int&)' previously defined here
   62 | bool CommandDispatcherBase::AddVariable(const __FlashStringHelper* pName, long& rVariable)
      |      ^~~~~~~~~~~~~~~~~~~~~
In file included from c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\UdpParser.h:3,
                 from c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\UdpParser.cpp:1:
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:61:10: error: 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, long unsigned int&)' cannot be overloaded with 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, uint32_t&)'
   61 |     bool AddVariable(const __FlashStringHelper* pName, unsigned long& rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:50:10: note: previous declaration 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, uint32_t&)'
   50 |     bool AddVariable(const __FlashStringHelper *pName, uint32_t &rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:62:10: error: 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, long int&)' cannot be overloaded with 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, int32_t&)'
   62 |     bool AddVariable(const __FlashStringHelper* pName, long& rVariable);
      |          ^~~~~~~~~~~
c:\Users\jonny\OneDrive\Documents\Arduino\libraries\MegunoLink\src\CommandDispatcherBase.h:53:10: note: previous declaration 'bool MLP::CommandDispatcherBase::AddVariable(const __FlashStringHelper*, int32_t&)'
   53 |     bool AddVariable(const __FlashStringHelper *pName, int32_t &rVariable);
      |          ^~~~~~~~~~~

exit status 1

Compilation error: exit status 1