Tag: lookup tables

gcc警告:标量初始化器周围的大括号

我有如下定义的查找表,我正在使用GCC。 当我编译时,我收到警告 warning: braces around scalar initializer 这个警告意味着什么? 我该如何初始化这个LUT? 我在初始化这个结构时犯了错误吗? 救命!! typedef struct TECH { float velocity1, velocity2; float temp; float measure; int id; float storage[64]; }TECH; struct TECH lut_model_1[2] = {{{296.001465}, {74.216972}, {2.025908}, {1.516384}, {1}, {0.001746, 0.000256, 0.006216, 0.005249, -0.001668, -0.001377, 0.009865, 0.010454, -0.000288, -0.005853, 0.010584, 0.015440, 0.000465, -0.000602, 0.004330, 0.005700, 0.017120, 0.233015, 0.034154, […]