libjmmcg  release_579_6_g8cffd
A C++ library containing an eclectic mix of useful, advanced components.
jmmcg::LIBJMMCG_VER_NAMESPACE::info::function Class Reference

Attempt to include function-call information for the function from which the exception was constructed. More...

#include <info.hpp>

Classes

class  argument
 Attempt to include argument information for the function from which the exception was constructed. More...
 

Public Types

typedef std::vector< argumentargs_details_type
 

Public Member Functions

NEVER_INLINE __stdcall function (const unsigned long l=__LINE__, const char *n=NULL, const std::type_info &th=typeid(void), const argument &a=argument(_T("void"), _T("nothing"))) noexcept(false)
 
void NEVER_INLINE __fastcall add_arg (argument &&a) noexcept(false)
 
template<class ... Args>
void NEVER_INLINE __fastcall add_args (Args &&...a) noexcept(false)
 
template<typename Arg_Val >
void NEVER_INLINE __fastcall add_arg (tstring &&n, const Arg_Val &v) noexcept(false)
 

Static Public Member Functions

static constexpr std::size_t max_size () noexcept(true)
 

Static Public Attributes

static constexpr std::size_t max_args =10
 

Friends

tostream &__fastcall operator<< (tostream &o, const function &fi) noexcept(false)
 

Detailed Description

Attempt to include function-call information for the function from which the exception was constructed.

Use of the macros JMMCG_FUNCTION (for no arguments) & JMMCG_FUNCTION1 (for one argument) make use of this object for constructing an exception easier.

See also
JMMCG_FUNCTION
JMMCG_FUNCTION1

Definition at line 88 of file info.hpp.

Member Typedef Documentation

◆ args_details_type

Constructor & Destructor Documentation

◆ function()

Member Function Documentation

◆ add_arg() [1/2]

◆ add_arg() [2/2]

template<typename Arg_Val >
void NEVER_INLINE __fastcall jmmcg::LIBJMMCG_VER_NAMESPACE::info::function::add_arg ( tstring &&  n,
const Arg_Val &  v 
)
inlinenoexcept

Definition at line 153 of file info.hpp.

References add_arg().

◆ add_args()

template<class ... Args>
void NEVER_INLINE __fastcall jmmcg::LIBJMMCG_VER_NAMESPACE::info::function::add_args ( Args &&...  a)
inlinenoexcept

Definition at line 144 of file info.hpp.

◆ max_size()

static constexpr std::size_t jmmcg::LIBJMMCG_VER_NAMESPACE::info::function::max_size ( )
inlinestaticconstexprnoexcept

Friends And Related Function Documentation

◆ operator<<

tostream& __fastcall operator<< ( tostream o,
const function fi 
)
friend
Todo:
Implement using the advice given in "Standard C++ IOStreams and Locales" by A.Langer & K.Kreft, page 170.

Definition at line 175 of file info.hpp.

Member Data Documentation

◆ max_args

constexpr std::size_t jmmcg::LIBJMMCG_VER_NAMESPACE::info::function::max_args =10
inlinestaticconstexpr

Definition at line 130 of file info.hpp.

Referenced by max_size().


The documentation for this class was generated from the following file: