nits: corrects the #endif position to the bottom of the generated header