Embedded functions...

This is a discussion on Embedded functions... within the C++ Programming forums, part of the General Programming Boards category; I'm constructing a rather large calculator and I need some help with nested (embedded) functions. I've declared some functions before ...

Embedded functions...

I'm constructing a rather large calculator and I need some help with nested (embedded) functions. I've declared some functions before the int main() operator, and I am currently wishing to place embedded functions within those mother functions...

Assuming that the code's function one() is being called from a switch case within the int main() function, and the add() is being called from a switch case within the one(), which way should I go about this, having the void blargh(void) inside the mother function one()? Or, should I declare the nested function add() as an int or a float?