]> git.tdb.fi Git - libs/core.git/blobdiff - source/strings/regmatch.h
Add some utility functions for joining strings
[libs/core.git] / source / strings / regmatch.h
index 19cac11027dac128f6cdd537fe771d3a2316a2d9..c5116cdc5408ec7238c65f6a250feb9bc23f8308 100644 (file)
@@ -1,10 +1,3 @@
-/* $Id$
-
-This file is part of libmspstrings
-Copyright © 2007 Mikko Rasa
-Distributed under the LGPL
-*/
-
 #ifndef MSP_STRINGS_REGMATCH_H_
 #define MSP_STRINGS_REGMATCH_H_
 
@@ -31,11 +24,13 @@ public:
        */
        struct Group
        {
-               bool match;       //< Whether or not this group matched
-               unsigned begin;   //< First offset of the match
-               unsigned end;     //< One-past-last offset
-               unsigned length;  //< Length of the match (end-begin)
-               std::string str;  //< The part of the string that matched
+               typedef std::string::size_type size_type;
+
+               bool match;        //< Whether or not this group matched
+               size_type begin;   //< First offset of the match
+               size_type end;     //< One-past-last offset
+               size_type length;  //< Length of the match (end-begin)
+               std::string str;   //< The part of the string that matched
 
                Group(): match(false) { }
                operator bool() const { return match; }