ARB
arb_stdstring.h
Go to the documentation of this file.
1 // ========================================================== //
2 // //
3 // File : arb_stdstring.h //
4 // Purpose : (inlined) string functions using std::string //
5 // //
6 // Coded by Ralf Westram (coder@reallysoft.de) in Sep 19 //
7 // http://www.arb-home.de/ //
8 // //
9 // ========================================================== //
10 
11 // Note: code using char* should go to arb_string.h
12 // or ../TEMPLATES/arb_str.h
13 
14 #ifndef ARB_STDSTRING_H
15 #define ARB_STDSTRING_H
16 
17 #ifndef ARB_STRING_H
18 #include "arb_string.h"
19 #endif
20 #ifndef _GLIBCXX_STRING
21 #include <string>
22 #endif
23 
24 inline char *ARB_stringdup(const std::string& str) {
25  return ARB_strduplen(str.c_str(), str.length());
26 }
27 
28 #else
29 #error arb_stdstring.h included twice
30 #endif // ARB_STDSTRING_H
return string(buffer, length)
char * ARB_stringdup(const std::string &str)
Definition: arb_stdstring.h:24
char * ARB_strduplen(const char *p, unsigned len)
Definition: arb_string.h:33