Tool/software: TI C/C++ Compiler
Hello!
This simple example:
struct Test1 {
const uint8_t t;
const int i;
const float f;
Test1(int _i) : t(0), i(_i), f(0) {}
Test1(float _f): t(1), i(0), f(_f) {}
};
const Test1 t1((int)12);
const Test1 t2((float)12.5);
should create const objects, as all fields are const and constructors are empty and just initializing fields, so this is compile-time definition (should be). In fact, after compilation during debug I see these objects are located in RAM, not FLASH, as I expect.
I need to define a constant array (large one) of such objects, so I need them in FLASH.