Avoid duplicate signed char generic association with MSVC - #535
Avoid duplicate signed char generic association with MSVC#535crazywhalecc wants to merge 2 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces conditional compilation macros to omit the signed char association from _Generic selection lists in nghttp3_max and nghttp3_min when compiling with MSVC. The review feedback correctly identifies that newer versions of MSVC (VS 2022 17.14+) and Clang conformantly treat signed char as a distinct type, meaning unconditional omission will lead to compilation failures. It is recommended to update the preprocessor checks to only omit the association on older MSVC versions when not compiling with Clang.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
What does this PR do?
MSVC rejects the
nghttp3_maxandnghttp3_min_Generic association lists because both signed char and char are present and are treated as compatible types, which causes C7700 errors when building nghttp3 with Visual Studio 2022.This change omits the signed char generic association only for MSVC, while preserving the existing behavior for other compilers. The actual nghttp3 call sites use integer, size_t, and uint64_t values, so this avoids the MSVC compile failure without changing the non-MSVC path.