Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of mbed-os by
utest_stack_trace.h
00001 00002 /** \addtogroup frameworks */ 00003 /** @{*/ 00004 /**************************************************************************** 00005 * Copyright (c) 2016, ARM Limited, All Rights Reserved 00006 * SPDX-License-Identifier: Apache-2.0 00007 * 00008 * Licensed under the Apache License, Version 2.0 (the "License"); you may 00009 * not use this file except in compliance with the License. 00010 * You may obtain a copy of the License at 00011 * 00012 * http://www.apache.org/licenses/LICENSE-2.0 00013 * 00014 * Unless required by applicable law or agreed to in writing, software 00015 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 00016 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00017 * See the License for the specific language governing permissions and 00018 * limitations under the License. 00019 **************************************************************************** 00020 */ 00021 00022 #ifndef UTEST_STACK_TRACE_H 00023 #define UTEST_STACK_TRACE_H 00024 00025 #ifdef UTEST_STACK_TRACE 00026 #include <string> 00027 00028 #define UTEST_MAX_BACKTRACE 100 00029 extern std::string utest_trace[UTEST_MAX_BACKTRACE]; 00030 00031 extern void utest_trace_initialise(); 00032 extern void utest_add_to_trace(char *func_name); 00033 extern void utest_dump_trace(); 00034 00035 #define UTEST_LOG_FUNCTION(); utest_add_to_trace((char *)__func__); 00036 #define UTEST_TRACE_START utest_trace_initialise(); 00037 #define UTEST_DUMP_TRACE utest_dump_trace(); 00038 00039 #else 00040 00041 #define UTEST_LOG_FUNCTION(); 00042 #define UTEST_TRACE_START 00043 #define UTEST_DUMP_TRACE 00044 00045 #endif // UTEST_STACK_TRACE 00046 00047 #endif // UTEST_STACK_TRACE_H 00048 00049 /** @}*/
Generated on Tue Jul 12 2022 13:16:19 by
