package "mspstrings"
{
+ description "Mikkosoft Productions string utilities library";
+ version "0.1";
+
require "mspcore";
library "mspstrings"
#define MSP_STRINGS_CODEC_H_
#include <string>
-#include <msp/core/error.h>
+#include <msp/core/except.h>
namespace Msp {
namespace Codecs {
Copyright © 2006-2007 Mikko Rasa
Distributed under the LGPL
*/
-#include <msp/core/error.h>
+#include <msp/core/except.h>
#include "fmt.h"
using namespace std;
#include <sstream>
#include <string>
-#include <msp/core/error.h>
+#include <msp/core/except.h>
#include "fmt.h"
namespace Msp {
Distributed under the LGPL
*/
#include <stack>
-#include <msp/core/error.h>
+#include <msp/core/except.h>
#include "formatter.h"
#include "regex.h"
Copyright © 2007 Mikko Rasa
Distributed under the LGPL
*/
-#include <msp/core/error.h>
+#include <msp/core/except.h>
#include "regmatch.h"
using namespace std;
*/
#include <list>
-#include <msp/core/error.h>
+#include <msp/core/except.h>
#include "utils.h"
using namespace std;
result+="\\\'";
else if(*i=='\\')
result+="\\\\";
- else if(*i<' ' || (escape_8bit && (*i&0x80)))
+ else if(static_cast<unsigned char>(*i)<' ' || (escape_8bit && (*i&0x80)))
{
- char buf[4]={'\\', (*i>>6)&7, (*i>>3)&7, *i&7};
+ char buf[4]={'\\', '0'+((*i>>6)&7), '0'+((*i>>3)&7), '0'+(*i&7)};
result.append(buf, 4);
}
else