Teuchos - Trilinos Tools Package Version of the Day
Loading...
Searching...
No Matches
Teuchos_stacktrace.hpp
Go to the documentation of this file.
1// @HEADER
2// *****************************************************************************
3// Teuchos: Common Tools Package
4//
5// Copyright 2004 NTESS and the Teuchos contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
10/*
11Copyright (c) 2010, Ondrej Certik
12All rights reserved.
13
14Redistribution and use in source and binary forms, with or without
15modification, are permitted provided that the following conditions are met:
16
17* Redistributions of source code must retain the above copyright notice, this
18 list of conditions and the following disclaimer.
19* Redistributions in binary form must reproduce the above copyright notice,
20 this list of conditions and the following disclaimer in the documentation
21 and/or other materials provided with the distribution.
22* Neither the name of the Sandia Corporation nor the names of its contributors
23 may be used to endorse or promote products derived from this software without
24 specific prior written permission.
25
26THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
27ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
28WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
29DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
30FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
31DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
32SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
33CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
34OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36*/
37
38#ifndef TEUCHOS_STACKTRACE_HPP
39#define TEUCHOS_STACKTRACE_HPP
40
47
48
49#ifdef HAVE_TEUCHOS_STACKTRACE
50
51
57namespace Teuchos {
58
59
64void store_stacktrace();
65
70std::string get_stored_stacktrace();
71
80std::string get_stacktrace(int impl_stacktrace_depth=0);
81
86void show_stacktrace();
87
92void print_stack_on_segfault();
93
94} // end namespace Teuchos
95
96#endif // HAVE_TEUCHOS_STACKTRACE
97
98#endif // TEUCHOS_STACKTRACE_HPP
99
Teuchos header file which uses auto-configuration information to include necessary C++ headers.
The Teuchos namespace contains all of the classes, structs and enums used by Teuchos,...