mirror of
https://github.com/python/cpython.git
synced 2025-10-17 20:28:43 +00:00
gh-123747: Avoid static_assert() in internal header files (#123779)
This commit is contained in:
parent
e95984826e
commit
ef4b69d2be
2 changed files with 9 additions and 4 deletions
|
@ -543,8 +543,9 @@ write_location_entry_start(uint8_t *ptr, int code, int length)
|
|||
#define ADAPTIVE_COOLDOWN_BACKOFF 0
|
||||
|
||||
// Can't assert this in pycore_backoff.h because of header order dependencies
|
||||
static_assert(SIDE_EXIT_INITIAL_VALUE > ADAPTIVE_COOLDOWN_VALUE,
|
||||
"Cold exit value should be larger than adaptive cooldown value");
|
||||
#if SIDE_EXIT_INITIAL_VALUE <= ADAPTIVE_COOLDOWN_VALUE
|
||||
# error "Cold exit value should be larger than adaptive cooldown value"
|
||||
#endif
|
||||
|
||||
static inline _Py_BackoffCounter
|
||||
adaptive_counter_bits(uint16_t value, uint16_t backoff) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue