Allow dllimport/dllexport on inline functions and adjust the linkage.

This is a step towards handling these attributes on classes (PR11170).

Differential Revision: http://reviews.llvm.org/D3772

llvm-svn: 208925
diff --git a/clang/test/CodeGen/dllexport.c b/clang/test/CodeGen/dllexport.c
new file mode 100644
index 0000000..ce5636c
--- /dev/null
+++ b/clang/test/CodeGen/dllexport.c
@@ -0,0 +1,8 @@
+// RUN: %clang_cc1 -triple i686-pc-win32 -std=c99 -O2 -disable-llvm-optzns -emit-llvm < %s | FileCheck %s
+
+#define DLLEXPORT __declspec(dllexport)
+
+inline void DLLEXPORT f() {}
+extern void DLLEXPORT f();
+
+// CHECK: define weak_odr dllexport void @f()