Comment by 1718627440

1 month ago

Sorry, but I wouldn't like that either. I often intentionally don't initialize members and don't want that to be an error. How would you initialize the following:

    struct S  {
         enum {
              NO_MODE,
              MODE_A,
              MODE_B,
              MODE_C,
         } mode;
         union {
             struct mode_a {
                 float x, y;
             } a;
             struct mode_c {
                 time_t start;
                 bool flag;
             } c;
         };
    };

    S s;
    s.mode = NO_MODE;

?