File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 33#include " xalloc.h"
44
55// string(char)
6- typedef std::basic_string<char , std::char_traits<char >, xalloc<char >> xr_string ;
6+ using xr_string = std::basic_string<char , std::char_traits<char >, xalloc<char >>;
77
88inline void xr_strlwr (xr_string& src)
99{
Original file line number Diff line number Diff line change 9696// stl ext
9797struct XRCORE_API xr_rtoken
9898{
99- shared_str name;
99+ xr_string name;
100100 int id;
101101
102- xr_rtoken (pcstr _nm, int _id)
102+ xr_rtoken (const pcstr _nm, const int _id)
103103 {
104104 name = _nm;
105105 id = _id;
106106 }
107107
108- void rename (pcstr _nm) { name = _nm; }
109- bool equal (pcstr _nm) const { return (0 == xr_strcmp (*name, _nm)); }
108+ void rename (const pcstr _nm) { name = _nm; }
109+ bool equal (const pcstr _nm) const
110+ {
111+ return name.compare (_nm) == 0 ;
112+ }
110113};
111114
112115#pragma pack(push, 1)
You can’t perform that action at this time.
0 commit comments