uppsrc: Visual C++ compiler bug [W]StringBuffer workaround

git-svn-id: svn://ultimatepp.org/upp/trunk@15123 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2020-09-23 09:37:31 +00:00
parent 313a4b1d90
commit 9293ed2be0
41 changed files with 99 additions and 99 deletions

View file

@ -10,7 +10,7 @@ String MakeSqlValue(int code, T& value)
StringBuffer b(sizeof(T) + 1);
b[0] = code;
memcpy(~b + 1, &value, sizeof(T));
return b;
return String(b);
}
template <class T>
@ -327,7 +327,7 @@ String SqlCompile(byte dialect, const String& s)
b.Reserve(s.GetLength() + 100);
const char *q = s;
SqlCompile(q, &b, dialect, NULL);
return b;
return String(b);
}
#ifndef NOAPPSQL
@ -370,7 +370,7 @@ String SqlFormat0(const char *s, int l, int code)
b[0] = code;
memcpy(~b + 1, &l, sizeof(int));
memcpy(~b + 1 + sizeof(int), s, l);
return b;
return String(b);
}
String SqlFormat(const char *s, int l)