mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 14:35:26 +00:00
Remove use of the inline keyword used as suggestion to compiler
Historically, the inline keyword was a strong suggestion to the compiler that it should inline the function marked inline. As compilers became better at optimising, this functionality has receded, and using inline as a suggestion to inline a function is obsolete. The compiler will happily ignore it and inline something else entirely if it finds that's a better optimisation. Therefore, remove all the occurences of the inline keyword with static functions inside single compilation unit and leave the decision whether to inline a function or not entirely on the compiler NOTE: We keep the usage the inline keyword when the purpose is to change the linkage behaviour.
This commit is contained in:
@@ -100,7 +100,7 @@ struct nsec3_chain_fixed {
|
||||
* Helper function used to calculate length of variable-length
|
||||
* data section in object pointed to by 'chain'.
|
||||
*/
|
||||
static inline size_t
|
||||
static size_t
|
||||
chain_length(struct nsec3_chain_fixed *chain) {
|
||||
return (chain->salt_length + 2 * chain->next_length);
|
||||
}
|
||||
@@ -1104,7 +1104,7 @@ _checknext(const vctx_t *vctx, const struct nsec3_chain_fixed *first,
|
||||
return (false);
|
||||
}
|
||||
|
||||
static inline bool
|
||||
static bool
|
||||
checknext(isc_mem_t *mctx, const vctx_t *vctx,
|
||||
const struct nsec3_chain_fixed *first, struct nsec3_chain_fixed *prev,
|
||||
const struct nsec3_chain_fixed *cur) {
|
||||
@@ -1117,7 +1117,7 @@ checknext(isc_mem_t *mctx, const vctx_t *vctx,
|
||||
return (result);
|
||||
}
|
||||
|
||||
static inline bool
|
||||
static bool
|
||||
checklast(isc_mem_t *mctx, const vctx_t *vctx, struct nsec3_chain_fixed *first,
|
||||
struct nsec3_chain_fixed *prev) {
|
||||
bool result = _checknext(vctx, prev, first);
|
||||
|
Reference in New Issue
Block a user