2016-09-28 09:56:06 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2016 Freie Universität Berlin
|
|
|
|
*
|
|
|
|
* This file is subject to the terms and conditions of the GNU Lesser
|
|
|
|
* General Public License v2.1. See the file LICENSE in the top level
|
|
|
|
* directory for more details.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @{
|
|
|
|
*
|
|
|
|
* @file
|
|
|
|
* @author Martine Lenders <mlenders@inf.fu-berlin.de>
|
|
|
|
*/
|
|
|
|
|
2016-11-18 15:44:25 +01:00
|
|
|
#include <stdio.h>
|
|
|
|
|
2016-09-28 09:56:06 +02:00
|
|
|
#include "assert.h"
|
2022-01-26 12:37:30 +01:00
|
|
|
#include "panic.h"
|
2016-09-28 09:56:06 +02:00
|
|
|
|
2022-01-26 12:37:30 +01:00
|
|
|
__NORETURN void _assert_failure(const char *file, unsigned line)
|
2016-09-28 09:56:06 +02:00
|
|
|
{
|
2022-01-26 12:37:30 +01:00
|
|
|
printf("%s:%u => ", file, line);
|
|
|
|
core_panic(PANIC_ASSERT_FAIL, "FAILED ASSERTION.");
|
|
|
|
}
|
|
|
|
|
|
|
|
__NORETURN void _assert_panic(void)
|
|
|
|
{
|
|
|
|
core_panic(PANIC_ASSERT_FAIL, "FAILED ASSERTION.");
|
2016-09-28 09:56:06 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
/** @} */
|