]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libgcc/gthr-posix.h
PR c++/87554 - ICE with extern template and reference member.
[thirdparty/gcc.git] / libgcc / gthr-posix.h
index 555c0fe2458fa3e0e96d769d3f36ae35db47e1bb..88cbc23937ec20b15b35c5adb7f9983282c6f084 100644 (file)
@@ -1,6 +1,6 @@
 /* Threads compatibility routines for libgcc2 and libobjc.  */
 /* Compile this one with gcc.  */
-/* Copyright (C) 1997-2016 Free Software Foundation, Inc.
+/* Copyright (C) 1997-2019 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -87,7 +87,8 @@ typedef struct timespec __gthread_time_t;
 #  define __gthrw_pragma(pragma)
 # endif
 # define __gthrw2(name,name2,type) \
-  static __typeof(type) name __attribute__ ((__weakref__(#name2))); \
+  static __typeof(type) name \
+    __attribute__ ((__weakref__(#name2), __copy__ (type))); \
   __gthrw_pragma(weak type)
 # define __gthrw_(name) __gthrw_ ## name
 #else