Esempio
struct CC
{
int n;
char c;
};


class Point{

public:
Point(int newx, int newy);

private:
int x;
int y;

CC myStructure;
};

Point::Point(int newx, int newy): x(newx) {

myStructure.n = 2;
}

Soluzione
Inizializzare sempre tutti i campi in un costruttore.

struct CC
{
int n;
char c;
};


class Point{

public:
Point(int newx, int newy);

private:
int x;
int y;

CC myStructure;
};

Point::Point(int newx, int newy) : x(newx), y(newy) {

myStructure.n = 1;
myStructure.c = 'a';
}