I have search through google/stack overflow etc. but I could not find the proper/exact solution for this. I know latest C++ revision supports Lambda function by which we can achieve, and also I know we should avoid defining a function inside another function. But I'm curious why can not we have function definition inside function according to C++ standard?.
like following:
int print(){
void test(){
//statements
}
}
Aucun commentaire:
Enregistrer un commentaire