Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修正API的参数个数信息 #116

Merged

Conversation

sonyps5201314
Copy link
Contributor

@sonyps5201314 sonyps5201314 commented Sep 13, 2024

可通过应用下面这个补丁后,编译YY-Thunks.UnitTest的x86配置来快速发现这些声明错误的条目

 src/Thunks/YY_Thunks.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/Thunks/YY_Thunks.cpp b/src/Thunks/YY_Thunks.cpp
index 7b2f9b4..205b624 100644
--- a/src/Thunks/YY_Thunks.cpp
+++ b/src/Thunks/YY_Thunks.cpp
@@ -248,6 +248,7 @@ RtlCutoverTimeToSystemTime(
 #define __DEFINE_THUNK_EXTERN_PREFIX(_PREFIX, _MODULE, _SIZE, _RETURN_, _CONVENTION_, _FUNCTION, ...)                      \
     __APPLY_UNIT_TEST_BOOL(_FUNCTION);                                                                                     \
     EXTERN_C _RETURN_ _CONVENTION_ _CRT_CONCATENATE_(_PREFIX, _FUNCTION)(__VA_ARGS__);                                     \
+    __pragma(comment(linker, "/export:"#_FUNCTION"=_"#_FUNCTION"@"#_SIZE))                                                 \
     static decltype(_CRT_CONCATENATE_(_PREFIX, _FUNCTION))* __cdecl _CRT_CONCATENATE(try_get_, _FUNCTION)() noexcept;      \
     __if_not_exists(_CRT_CONCATENATE(try_get_, _FUNCTION))

@mingkuang-Chuyu mingkuang-Chuyu merged commit de3384d into Chuyu-Team:Rel/v1.1.3-Beta Sep 13, 2024
1 check failed
@mingkuang-Chuyu mingkuang-Chuyu added 类型:问题 程序不工作,或者遇到错误。 labels Sep 13, 2024
@sonyps5201314 sonyps5201314 deleted the FixParamCount branch September 14, 2024 06:22
@mingkuang-Chuyu mingkuang-Chuyu linked an issue Sep 19, 2024 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
类型:问题 程序不工作,或者遇到错误。
Projects
None yet
Development

Successfully merging this pull request may close these issues.

某些API系统引入版本错误或者IAT符号错误
2 participants