Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
Catch::StringMaker< std::string > Struct Reference

#include <catch_tostring.h>

Static Public Member Functions

static std::string convert (const std::string &str)
 
static std::string convert (const std::string &str)
 

Detailed Description

Definition at line 1339 of file catch.hpp.

Member Function Documentation

◆ convert() [1/2]

std::string Catch::StringMaker< std::string >::convert ( const std::string & str)
static

Definition at line 97 of file catch_tostring.cpp.

97 {
98 if (!getCurrentContext().getConfig()->showInvisibles()) {
99 return '"' + str + '"';
100 }
101
102 std::string s("\"");
103 for (char c : str) {
104 switch (c) {
105 case '\n':
106 s.append("\\n");
107 break;
108 case '\t':
109 s.append("\\t");
110 break;
111 default:
112 s.push_back(c);
113 break;
114 }
115 }
116 s.append("\"");
117 return s;
118}
return str
Definition CLI11.hpp:1359
IContext & getCurrentContext()
char * s
Here is the call graph for this function:

◆ convert() [2/2]

static std::string Catch::StringMaker< std::string >::convert ( const std::string & str)
static

The documentation for this struct was generated from the following files: