Merge bitcoin-core/secp256k1#1231: Move SECP256K1_INLINE macro definition out from include/secp256k1.h
8e142ca410Move `SECP256K1_INLINE` macro definition out from `include/secp256k1.h` (Hennadii Stepanov)77445898a5Remove `SECP256K1_INLINE` usage from examples (Hennadii Stepanov) Pull request description: From [IRC](https://gnusha.org/secp256k1/2023-01-31.log): > 06:29 \< hebasto\> What are reasons to define the `SECP256K1_INLINE` macro in user's `include/secp256k1.h` header, while it is used internally only? > 06:32 \< hebasto\> I mean, any other (or a new dedicated) header in `src` looks more appropriate, no? > 06:35 \< sipa\> I think it may just predate any "utility" internal headers. > 06:42 \< sipa\> I think it makes sense to move it to util.h Pros: - it is a step in direction to better organized headers (in context of #924, #1039) Cons: - code duplication for `SECP256K1_GNUC_PREREQ` macro ACKs for top commit: sipa: utACK8e142ca410real-or-random: utACK8e142ca410Tree-SHA512: 180e0ba7c2ef242b765f20698b67d06c492b7b70866c21db27c18d8b2e85c3e11f86c6cb99ffa88bbd23891ce3ee8a24bc528f2c91167ec2fddc167463f78eac
This commit is contained in:
@@ -122,18 +122,6 @@ typedef int (*secp256k1_nonce_function)(
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# if (!defined(__STDC_VERSION__) || (__STDC_VERSION__ < 199901L) )
|
||||
# if SECP256K1_GNUC_PREREQ(2,7)
|
||||
# define SECP256K1_INLINE __inline__
|
||||
# elif (defined(_MSC_VER))
|
||||
# define SECP256K1_INLINE __inline
|
||||
# else
|
||||
# define SECP256K1_INLINE
|
||||
# endif
|
||||
# else
|
||||
# define SECP256K1_INLINE inline
|
||||
# endif
|
||||
|
||||
/* When this header is used at build-time the SECP256K1_BUILD define needs to be set
|
||||
* to correctly setup export attributes and nullness checks. This is normally done
|
||||
* by secp256k1.c but to guard against this header being included before secp256k1.c
|
||||
|
||||
Reference in New Issue
Block a user