0
0
mirror of https://github.com/mongodb/mongo.git synced 2024-12-01 09:32:32 +01:00
This commit is contained in:
Aaron 2011-04-26 15:26:16 -07:00
parent 4786360d41
commit 2c05215281
2 changed files with 3 additions and 3 deletions

View File

@ -222,7 +222,7 @@ namespace mongo {
* indexes and the other representing constraints for multi key indexes and
* unindexed scans. In several member functions the caller is asked to
* supply an index so that the implementation may utilize the proper
* FieldRangeSet and return results that are appropriate with respect to the
* FieldRangeSet and return results that are appropriate with respect to that
* supplied index.
*/
class FieldRangeSetPair {

View File

@ -104,13 +104,13 @@ namespace mongoutils {
return strchr(s.c_str(), x) != 0;
}
/** @return everything befor the character x, else entire string */
/** @return everything before the character x, else entire string */
inline string before(const string& s, char x) {
const char *p = strchr(s.c_str(), x);
return (p != 0) ? s.substr(0, p-s.c_str()) : s;
}
/** @return everything befor the string x, else entire string */
/** @return everything before the string x, else entire string */
inline string before(const string& s, const string& x) {
const char *p = strstr(s.c_str(), x.c_str());
return (p != 0) ? s.substr(0, p-s.c_str()) : s;