Free Ground Shipping on all orders over $100 (US Only)
login   |   Register

Welcome Forums Tarts for Raspberry Pi libTarts doesnt compile; loss of precision casting 'this' as int

This topic contains 0 replies, has 1 voice, and was last updated by rock64user rock64user 1 year, 1 month ago.

  • Author
    Posts
  • #7063
    rock64user
    rock64user
    Participant

    ts.cpp: In constructor ‘TartsGateway::TartsGateway(const char*, uint32_t, uint8_t, uint8_t, uint8_t)’: Tarts.cpp:276:48: error: cast from ‘TartsGateway*’ to ‘int’ loses precision [-fpermissive]
    _freeOnRemove = isHeapStackVarNotGlobal((int)this); //Decide on how to dispose of this
    ^~~~ Tarts.cpp: In member function ‘void TartsLib::RemoveSensor(const char*)’:
    Tarts.cpp:568:38: warning: deleting object of abstract class type ‘TartsSensorBase’ which has non-virtual destructor will cause undefined behavior [-Wdelete-non-virtual-dtor]
    if(senObj->_freeOnRemove) delete senObj; ^~~~~~
    make: *** [Tarts.o] Error 1 make install > /dev/null 8.45s user 0.49s system 101% cpu

You must be logged in to reply to this topic.

Support
Contact Us!

Your Name (required)

Your Email (required)

Subject

Your Message

Enter this code below: To use CAPTCHA, you need Really Simple CAPTCHA plugin installed.