]> granicus.if.org Git - clang/commit
[-cxx-abi microsoft] Correctly identify Win32 entry points
authorDavid Majnemer <david.majnemer@gmail.com>
Mon, 16 Sep 2013 22:44:20 +0000 (22:44 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Mon, 16 Sep 2013 22:44:20 +0000 (22:44 +0000)
commite9f6f33f0cf98a3e39025a57a0079cd316ed98f8
tree7f75d092811f1f3d3c2375b7ff9800169745a89b
parent225e9826336f85166cbc4636ae61028f6f7868be
[-cxx-abi microsoft] Correctly identify Win32 entry points

Summary:
This fixes several issues with the original implementation:
- Win32 entry points cannot be in namespaces
- A Win32 entry point cannot be a function template, diagnose if we it.
- Win32 entry points cannot be overloaded.
- Win32 entry points implicitly return, similar to main.

Reviewers: rnk, rsmith, whunt, timurrrr

Reviewed By: rnk

CC: cfe-commits, nrieck
Differential Revision: http://llvm-reviews.chandlerc.com/D1683

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190818 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/Decl.h
include/clang/Basic/DiagnosticSemaKinds.td
include/clang/Sema/Sema.h
lib/AST/Decl.cpp
lib/AST/MicrosoftMangle.cpp
lib/Sema/SemaDecl.cpp
lib/Sema/SemaOverload.cpp
test/SemaCXX/ms-overload-entry-point.cpp [new file with mode: 0644]