• Initializing a struct
    Hi, I am trying to initialize a struct, but I get the following error: Error #29: Expected an expression typedef struct { atp V1; atp V2; atp V3; atp V4; } tosh_at; tosh_at tosh_options...
  • Array initialization inside struct
    Hello, I try compile this code (.c) with --c99 option struct sx { char c; char a[]; }; static struct sx xx = { 1, {[5] = 0} }; and have error error: #146: too many initializer values How...
  • Is it possible to partially initialize a struct?
    Hi, my question is to ask whether or not it is possible to partially initialize a struct in C language with Keil C166 compiler. According to C syntax [1], it should be possible to do things like...
  • Initializing array of structs
    Hello, I have an array of structs, which I would like to initialize at startup, but to my surprise this gives me a compiler syntax error: I do as follows: typedef volatile struct Timer {...
  • const struct/unon initialization proble.
    Hi, with the following sample code... typedef __packed struct { uint8_t field_1; uint8_t field_2; uint8_t field_3; uint8_t field_4; } T_Sub; typedef __packed struct { T_Sub Sub; uint8_t...