class Test{ int &b; // no error, can compile};int main() { int &b; // error: 'b' declared as reference but not initialized }
Why I cant have int &b in main function, but can have it in Test class?
Aucun commentaire:
Enregistrer un commentaire