libcsdbg  1.28
C++ exception (and generic) stack trace debug library
string & csdbg::string::insert ( u32  pos,
const i8 fmt,
  ... 
)
virtual

Insert a printf-style format C-string expanded with the values of a variable argument list, at a specified position.

Parameters
[in]posthe insertion position
[in]fmta printf-style format C-string
[in]...a variable argument list
Returns
*this
Exceptions
std::bad_alloc
csdbg::exception

Definition at line 612 of file string.cpp.

References __D_ASSERT, format(), insert(), and unlikely.

613 {
614  __D_ASSERT(fmt != NULL);
615  if ( unlikely(fmt == NULL) )
616  return *this;
617 
618  /* Format a temporary string */
619  string tmp;
620  va_list args;
621  va_start(args, fmt);
622  tmp.format(fmt, args);
623 
624  return insert(pos, tmp);
625 }
virtual string & insert(u32, const string &)
Insert a string at a specified position.
Definition: string.cpp:575
#define unlikely(expr)
Offer a hint (negative) to the pipeline branch predictor.
Definition: config.hpp:349
#define __D_ASSERT(x)
Assertion macro.
Definition: config.hpp:268

+ Here is the call graph for this function: