diff options
author | Cory Fields <cory-nospam-@coryfields.com> | 2020-07-08 12:52:14 -0400 |
---|---|---|
committer | Cory Fields <cory-nospam-@coryfields.com> | 2020-07-08 13:31:56 -0400 |
commit | e3e7446305329ce96e9cf5f5161658eb2e1ea888 (patch) | |
tree | c0900eade42e5240f87b8ccfb4ea7671e5fd292c /src/attributes.h | |
parent | 1d58cc7cb040a70f768b632f294db4e0797d3a34 (diff) |
Add lifetimebound to attributes for general-purpose usage
Co-authored-by: practicalswift <practicalswift@users.noreply.github.com>
Diffstat (limited to 'src/attributes.h')
-rw-r--r-- | src/attributes.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/attributes.h b/src/attributes.h index 45099bd8b8..9d5c1d44a0 100644 --- a/src/attributes.h +++ b/src/attributes.h @@ -19,4 +19,14 @@ # endif #endif +#if defined(__clang__) +# if __has_attribute(lifetimebound) +# define LIFETIMEBOUND [[clang::lifetimebound]] +# else +# define LIFETIMEBOUND +# endif +#else +# define LIFETIMEBOUND +#endif + #endif // BITCOIN_ATTRIBUTES_H |