kopia lustrzana https://github.com/espressif/esp-idf
newlib/assert: placed unlikely macro as part of assertion
newlib/assert: replace unlikely with likely to keep original assertion newlib/assert: fix assert macro that uses likely freertos/port: add the missing sdkconfig.h back newlib/assert: assert macro back to a single linepull/4623/head
rodzic
fc00236d79
commit
1b76253e0e
|
@ -90,7 +90,6 @@
|
|||
// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
--------------------------------------------------------------------------------
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <xtensa/config/core.h>
|
||||
|
|
|
@ -19,10 +19,12 @@
|
|||
#pragma once
|
||||
#include <sdkconfig.h>
|
||||
#include <stdlib.h>
|
||||
#include "esp_compiler.h"
|
||||
|
||||
#include_next <assert.h>
|
||||
|
||||
|
||||
#if defined(CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_SILENT) && !defined(NDEBUG)
|
||||
#undef assert
|
||||
#define assert(__e) ((__e) ? (void)0 : abort())
|
||||
#define assert(__e) (likely(__e)) ? (void)0 : abort()
|
||||
#endif
|
||||
|
|
Ładowanie…
Reference in New Issue