Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
demangle.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2019 Roc authors
3  *
4  * This Source Code Form is subject to the terms of the Mozilla Public
5  * License, v. 2.0. If a copy of the MPL was not distributed with this
6  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
7  */
8 
9 //! @file roc_core/demangle.h
10 //! @brief Symbol demangling.
11 
12 #ifndef ROC_CORE_DEMANGLE_H_
13 #define ROC_CORE_DEMANGLE_H_
14 
15 #include "roc_core/stddefs.h"
16 
17 namespace roc {
18 namespace core {
19 
20 //! Demangle symbol name.
21 //!
22 //! This function is not signal-safe.
23 //!
24 //! @remarks
25 //! @p demangled_buf and @p demangled_size specify the buffer for demangled name.
26 //! When necessary, this function malloc()s or realloc()s @p demangled_buf and
27 //! updates @p demangled_size accrodingly. The buffer may be NULL. The buffer may
28 //! be resused across several calls. The user should manually free() the buffer
29 //! when it's not needed anymore.
30 //!
31 //! @returns
32 //! demangled symbol or NULL if the symbol can't be demangled.
33 const char* demangle(const char* mangled, char*& demangled_buf, size_t& demangled_size);
34 
35 } // namespace core
36 } // namespace roc
37 
38 #endif // ROC_CORE_DEMANGLE_H_
Root namespace.
Commonly used types and functions.
const char * demangle(const char *mangled, char *&demangled_buf, size_t &demangled_size)
Demangle symbol name.