Sema: correct handling for __va_start for WoA
Windows ARM indicates __va_start as a variadic function. However, the function itself is treated as having 4 formal arguments: - (out) pointer to the va_list - (in) address of the last named argument - (in) slot size for the type of the last argument - address of the last named argument The last argument does not seem to have any bearing on codegen, and thus is not explicitly type checked at this point. Unlike the previous handling for __va_start, it does not currently validate if the parameter is the last named parameter (it seems that MSVC currently accepts this). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213595 91177308-0d34-0410-b5e6-96231b3b80d8
Showing
- include/clang/Sema/Sema.h 1 addition, 0 deletionsinclude/clang/Sema/Sema.h
- lib/Sema/SemaChecking.cpp 66 additions, 1 deletionlib/Sema/SemaChecking.cpp
- test/SemaCXX/microsoft-varargs-diagnostics.cpp 42 additions, 0 deletionstest/SemaCXX/microsoft-varargs-diagnostics.cpp
- test/SemaCXX/microsoft-varargs.cpp 22 additions, 0 deletionstest/SemaCXX/microsoft-varargs.cpp
Loading
Please register or sign in to comment