Piotr Caban (@piotr) commented about dlls/ucrtbase/tests/misc.c:
- "call " __ASM_NAME("rewind") "\n\t"
- "popl %eax\n\t"
- "ret")
+#else +FILE* CDECL test_rewind_wrapper(FILE* fp); +__declspec(naked) FILE* test_rewind_wrapper(FILE *fp) +{
- __asm
- {
push [esp + 4];
call rewind;
pop eax;
ret;
- }
+} +#endif
I don't know if it's portable enough. How about changing it so it's done in similar way as in other tests? (see thiscall_thunk in dlls/msvcrt/tests/cpp.c for an example).