[libcxx-commits] [libcxx] r352525 - [libc++] Fix Windows build error in include/filesystem

Thomas Anderson via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jan 29 10:48:35 PST 2019


Author: thomasanderson
Date: Tue Jan 29 10:48:35 2019
New Revision: 352525

URL: http://llvm.org/viewvc/llvm-project?rev=352525&view=rev
Log:
[libc++] Fix Windows build error in include/filesystem

_LIBCPP_FUNC_VIS is redundant since the class is already annotated with
_LIBCPP_EXCEPTION_ABI.

Fixes this build error:

    In file included from fstream:188:
    filesystem(1350,3):  error: attribute 'dllimport' cannot be applied to member of 'dllimport' class
      _LIBCPP_FUNC_VIS
    __config(674,37):  note: expanded from macro '_LIBCPP_FUNC_VIS'
    #define _LIBCPP_FUNC_VIS            _LIBCPP_DLL_VIS
    __config(666,38):  note: expanded from macro '_LIBCPP_DLL_VIS'
    #  define _LIBCPP_DLL_VIS __declspec(dllimport)
    filesystem(1313,7):  note: previous attribute is here
    class _LIBCPP_EXCEPTION_ABI filesystem_error : public system_error {
    __config(675,37):  note: expanded from macro '_LIBCPP_EXCEPTION_ABI'
    #define _LIBCPP_EXCEPTION_ABI       _LIBCPP_DLL_VIS
    __config(666,38):  note: expanded from macro '_LIBCPP_DLL_VIS'
    #  define _LIBCPP_DLL_VIS __declspec(dllimport)

Differential Revision: https://reviews.llvm.org/D57354

Modified:
    libcxx/trunk/include/filesystem

Modified: libcxx/trunk/include/filesystem
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/filesystem?rev=352525&r1=352524&r2=352525&view=diff
==============================================================================
--- libcxx/trunk/include/filesystem (original)
+++ libcxx/trunk/include/filesystem Tue Jan 29 10:48:35 2019
@@ -1347,7 +1347,6 @@ public:
     return __storage_->__what_.c_str();
   }
 
-  _LIBCPP_FUNC_VIS
   void __create_what(int __num_paths);
 
 private:




More information about the libcxx-commits mailing list