diff options
author | hselasky <hselasky@FreeBSD.org> | 2015-06-23 22:40:22 +0000 |
---|---|---|
committer | hselasky <hselasky@FreeBSD.org> | 2015-06-23 22:40:22 +0000 |
commit | 9d59296130288d2473f67a67ddf7ec0795756ec9 (patch) | |
tree | 6ffa05eed42dd077bf6c453d74138b9c67d45c3a | |
parent | a9a29f86fd8de7fe1644712d7c246e76d094db7d (diff) | |
download | FreeBSD-src-9d59296130288d2473f67a67ddf7ec0795756ec9.zip FreeBSD-src-9d59296130288d2473f67a67ddf7ec0795756ec9.tar.gz |
Rename __weak to __weak_symbol to avoid language conflict with objective-C.
PR: 200972 (exp-run)
Suggested by: theraven@
MFC after: 3 days
-rw-r--r-- | sys/sys/cdefs.h | 4 | ||||
-rw-r--r-- | sys/sys/linker_set.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index 82cdc6e..1fb9875 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -213,9 +213,9 @@ #define __packed #define __aligned(x) #define __section(x) -#define __weak +#define __weak_symbol #else -#define __weak __attribute__((__weak__)) +#define __weak_symbol __attribute__((__weak__)) #if !__GNUC_PREREQ__(2, 5) && !defined(__INTEL_COMPILER) #define __dead2 #define __pure2 diff --git a/sys/sys/linker_set.h b/sys/sys/linker_set.h index 5742ec6..eaffcd1 100644 --- a/sys/sys/linker_set.h +++ b/sys/sys/linker_set.h @@ -80,8 +80,8 @@ * Initialize before referring to a given linker set. */ #define SET_DECLARE(set, ptype) \ - extern ptype __weak *__CONCAT(__start_set_,set); \ - extern ptype __weak *__CONCAT(__stop_set_,set) + extern ptype __weak_symbol *__CONCAT(__start_set_,set); \ + extern ptype __weak_symbol *__CONCAT(__stop_set_,set) #define SET_BEGIN(set) \ (&__CONCAT(__start_set_,set)) |