--- parser3/src/include/pa_string.h 2015/04/08 17:36:19 1.207 +++ parser3/src/include/pa_string.h 2015/10/06 22:20:50 1.210 @@ -8,7 +8,7 @@ #ifndef PA_STRING_H #define PA_STRING_H -#define IDENT_PA_STRING_H "$Id: pa_string.h,v 1.207 2015/04/08 17:36:19 moko Exp $" +#define IDENT_PA_STRING_H "$Id: pa_string.h,v 1.210 2015/10/06 22:20:50 moko Exp $" // includes #include "pa_types.h" @@ -22,7 +22,7 @@ extern "C" { // cord's author forgot to #define CORD_cat(x, y) CORD_cat_optimized(x, y) #define CORD_cat_char_star(x, y, leny) CORD_cat_char_star_optimized(x, y, leny) #endif -}; +} // defines @@ -55,6 +55,7 @@ class VRegex; int pa_atoi(const char* str, const String* problem_source=0); double pa_atod(const char* str, const String* problem_source=0); unsigned int pa_atoui(const char *str, int base, const String* problem_source=0); +unsigned long long int pa_atoul(const char *str, int base, const String* problem_source=0); /// this is result of pos functions which mean that substr were not found #define STRING_NOT_FOUND ((size_t)-1) @@ -185,7 +186,7 @@ public: assert(alang); assert(length); - if(!opt.is_not_just_lang) + if(!opt.is_not_just_lang) { if(opt.lang) { if(opt.lang==alang) // same language? ignoring return; @@ -193,6 +194,7 @@ public: opt.lang=alang; // to uninitialized return; } + } append(current, CORD_chars((char)alang, length)); } @@ -201,7 +203,7 @@ public: assert(alang); assert(length); - if(!opt.is_not_just_lang) + if(!opt.is_not_just_lang) { if(opt.lang) { if(opt.lang==alang) // same language? ignoring return; @@ -209,6 +211,7 @@ public: opt.lang=alang; // to uninitialized return; } + } append(current, CORD_chars((char)alang, length)); } @@ -216,7 +219,7 @@ public: void appendHelper(const Body& current, Language alang, const Body &length_helper) { assert(alang); - if(!opt.is_not_just_lang) + if(!opt.is_not_just_lang) { if(opt.lang) { if(opt.lang==alang) // same language? ignoring return; @@ -224,6 +227,7 @@ public: opt.lang=alang; // to uninitialized return; } + } append(current, CORD_chars((char)alang, length_helper.length())); }