#includeStdStrBuf buf; if (!buf.getLength()) { assert(buf.getData()[0] == '\0'); printf("Buffer is empty."); }
#includeStdStrBuf buf; buf.Append("Hello, "); buf.Append("World!"); if (buf.getLength()) { assert(buf.getData()[0] == 'H'); printf("Buffer data: %s", buf.getData()); }
#includeThese examples belong to the package library called SGDK (Sega Genesis Development Kit), which is a set of libraries used in game development for Sega Genesis/Mega Drive consoles.StdStrBuf buf; buf.Append("Hello, "); buf.Append("World!"); if (buf.getLength()) { buf.Clear(); assert(buf.getLength() == 0); printf("Buffer is cleared."); }