mirror of
https://github.com/Relintai/rcpp_framework.git
synced 2025-05-02 13:47:56 +02:00
get_slice_count should return 1 by default.
This commit is contained in:
parent
cefea40d45
commit
6bfc78ec49
@ -369,7 +369,7 @@ int String::get_slice_count(const char splitter) const {
|
|||||||
return count;
|
return count;
|
||||||
}
|
}
|
||||||
int String::get_slice_count(const String &splitter) const {
|
int String::get_slice_count(const String &splitter) const {
|
||||||
int count = 0;
|
int count = 1;
|
||||||
|
|
||||||
int n = find(splitter, n);
|
int n = find(splitter, n);
|
||||||
while (n != -1) {
|
while (n != -1) {
|
||||||
|
Loading…
Reference in New Issue
Block a user