// Gh_compiler_option.cpp
// compile with: /Gh
// processor: x86
#include <stdio.h>
void x() {}
int main() {
x();
}
extern "C" void __declspec(naked) _cdecl _penter( void ) {
_asm {
push eax
push ebx
push ecx
push edx
push ebp
push edi
push esi
}
printf_s("\nIn a function!");
_asm {
pop esi
pop edi
pop ebp
pop edx
pop ecx
pop ebx
pop eax
ret
}
}