diff options
| author | Trutz Behn | 2015-03-14 20:06:48 +0100 |
|---|---|---|
| committer | sin | 2015-03-14 20:37:27 +0000 |
| commit | 22e7e51007f3a28ded43f6cb8f0ff59a7a691175 (patch) | |
| tree | 3d2ca7e61136adc3f77b817e117699918e0c223a /include/strings.h | |
| parent | c2c9d0c6c8a1d74f748aa2ad9442957a37091062 (diff) | |
Use __typeof__ to in part avoid replicating function types
Diffstat (limited to 'include/strings.h')
| -rw-r--r-- | include/strings.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/include/strings.h b/include/strings.h index 02811a3..2a16c60 100644 --- a/include/strings.h +++ b/include/strings.h | |||
| @@ -14,8 +14,7 @@ extern "C" { | |||
| 14 | || (defined(_XOPEN_SOURCE) && _XOPEN_SOURCE+0 < 700) | 14 | || (defined(_XOPEN_SOURCE) && _XOPEN_SOURCE+0 < 700) |
| 15 | #undef bcopy | 15 | #undef bcopy |
| 16 | #undef bzero | 16 | #undef bzero |
| 17 | extern void __bcopy_orig(const void *, void *, size_t) | 17 | __typeof__(bcopy) __bcopy_orig __asm__(__USER_LABEL_PREFIX__ "bcopy"); |
| 18 | __asm__(__USER_LABEL_PREFIX__ "bcopy"); | ||
| 19 | extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__)) | 18 | extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__)) |
| 20 | void bcopy(const void *src, void *dest, size_t n) | 19 | void bcopy(const void *src, void *dest, size_t n) |
| 21 | { | 20 | { |
| @@ -26,8 +25,7 @@ void bcopy(const void *src, void *dest, size_t n) | |||
| 26 | return __bcopy_orig(src, dest, n); | 25 | return __bcopy_orig(src, dest, n); |
| 27 | } | 26 | } |
| 28 | 27 | ||
| 29 | extern void __bzero_orig(void *, size_t) | 28 | __typeof__(bzero) __bzero_orig __asm__(__USER_LABEL_PREFIX__ "bzero"); |
| 30 | __asm__(__USER_LABEL_PREFIX__ "bzero"); | ||
| 31 | extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__)) | 29 | extern __inline __attribute__((__always_inline__,__gnu_inline__,__artificial__)) |
| 32 | void bzero(void *src, size_t n) | 30 | void bzero(void *src, size_t n) |
| 33 | { | 31 | { |
