1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-02-21 20:27:13 +01:00

Don't compute string length twice.

This commit is contained in:
Sandu Liviu Catalin 2019-02-09 19:49:04 +02:00
parent d0c8dc3071
commit 7934b65de9

View File

@ -52,8 +52,8 @@ public:
static void Get(const SQChar* name, int args, string & out) {
SQChar buf[16] = {'_', 'o'};
I32ToA_(args, &buf[2]);
out.append(buf);
unsigned l = I32ToA(args, &buf[2]);
out.append(buf, l);
out.push_back('_');
out.append(name);
}