1
0
mirror of https://github.com/meekrosoft/fff synced 2026-01-23 08:25:59 +01:00

Custom return value delegate sequences for variadic functions (#63)

* Custom return value delegate sequences for variadic functions
* Added unit tests for variadic functions custom return value delegate sequences
* Fixes in code style
* Variadic functions custom delegates also tested in C++
* Fixed some compilation warnings
* Added test for variadic function custom delegates sequence reset
* Updated documentation with variadic functions custom delegate sequences
* Update README.md
* Minor style changes.

Thank you very much @oliviera9!
This commit is contained in:
Alain
2018-12-05 13:36:32 +01:00
committed by James Fraser
parent 35b26878a7
commit b76c7c7168
8 changed files with 841 additions and 86 deletions

View File

@@ -22,6 +22,8 @@ FAKE_VOID_FUNC(voidfunc1, int);
FAKE_VOID_FUNC(voidfunc2, char, char);
FAKE_VOID_FUNC(voidfunc1outparam, char *);
FAKE_VALUE_FUNC(long, longfunc0);
FAKE_VOID_FUNC_VARARG(voidfunc3var, const char *, int, ...);
FAKE_VALUE_FUNC_VARARG(int, valuefunc3var, const char *, int, ...);
FAKE_VOID_FUNC(voidfunc20, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int);
FAKE_VALUE_FUNC(int, valuefunc20, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int);
#else
@@ -29,6 +31,8 @@ FAKE_VOID_FUNC(__cdecl, voidfunc1, int);
FAKE_VOID_FUNC(__cdecl, voidfunc2, char, char);
FAKE_VOID_FUNC(__cdecl, voidfunc1outparam, char *);
FAKE_VALUE_FUNC(long, __cdecl, longfunc0);
FAKE_VOID_FUNC_VARARG(__cdecl, voidfunc3var, const char *, int, ...);
FAKE_VALUE_FUNC_VARARG(int, __cdecl, valuefunc3var, const char *, int, ...);
FAKE_VOID_FUNC(__cdecl, voidfunc20, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int);
FAKE_VALUE_FUNC(int, __cdecl, valuefunc20, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int);
#endif
@@ -42,6 +46,8 @@ public:
RESET_FAKE(voidfunc2);
RESET_FAKE(longfunc0);
RESET_FAKE(voidfunc1outparam);
RESET_FAKE(voidfunc3var);
RESET_FAKE(valuefunc3var);
FFF_RESET_HISTORY();
}
};