blob: 648fd6fc8a4809acb38a92a3a17f42e97dbb09c2 [file] [log] [blame]
Antonio de Angelis6bceab82025-07-10 17:05:14 +01001/*
2 * SPDX-FileCopyrightText: Copyright The TrustedFirmware-M Contributors
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 *
6 */
7
8#include <stddef.h>
9#include <assert.h>
10#include "tfm_tests_log_msg.h"
11
12#ifndef __ARMCC_VERSION
13void __assert_func(const char *file, int line, const char *func, const char *reason)
14{
15 LOG_MSG("Assertion failed: (%s), file %s, line %d\r\n", reason, file, line);
16
17 while (1) {
18 ;
19 }
20}
21#else /* __ARMCC_VERSION */
22void __assert_puts(const char *msg)
23{
24 LOG_MSG("%s\r\n", msg);
25
26 while (1) {
27 ;
28 }
29}
30#endif /* __ARMCC_VERSION*/