]> granicus.if.org Git - clang/commit
[Sema] Make FunctionType's TSI use unadjusted argument types
authorReid Kleckner <reid@kleckner.net>
Sat, 8 Jun 2013 17:28:56 +0000 (17:28 +0000)
committerReid Kleckner <reid@kleckner.net>
Sat, 8 Jun 2013 17:28:56 +0000 (17:28 +0000)
commit63c9a92a805394c1ca9e4a5fd8afb3acbb918d03
tree15eb40170cee8d6ff4e970a825b3c4ca3cb02ba9
parent122e601886ae527d6e7100c589339c05190a168a
[Sema] Make FunctionType's TSI use unadjusted argument types

This helps preserve the type-as-written in the AST, which we need for
MSVC mangling.  In particular, we need to preserve the types of array
parameters in function pointer types.

The essence of this change is:
-  QualType ArgTy = Param->getType();
+  QualType ArgTy = Param->getTypeSourceInfo()->getType();

... followed by the adjustment in ActOnFunctionDeclarator().

Differential Revision: http://llvm-reviews.chandlerc.com/D883

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183614 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/ASTContext.h
lib/AST/ASTContext.cpp
lib/AST/Type.cpp
lib/Sema/SemaDecl.cpp
lib/Sema/SemaType.cpp
test/Index/print-type.c
test/Index/print-type.cpp
test/Sema/function-redecl.c