This is a new one for me.

This is a new one for me. The C++ compiler error “local function definitions are illegal” usually means you’ve omitted a closing curly bracket, so the compiler thinks that your function declaration is inside the body of the previous function. Thanks internet!