Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Std::Split Error #3

Open
kadirkidir1 opened this issue Sep 16, 2022 · 0 comments
Open

Std::Split Error #3

kadirkidir1 opened this issue Sep 16, 2022 · 0 comments

Comments

@kadirkidir1
Copy link

Hi!

ı'm tried to run your Usecases but i received some exception error. I'm using G++4.9.2. When i searched error, i discovered this.
// KeypleStd.h
template
inline void split(const std::string &s, const std::regex& re, out result)
{
std::sregex_token_iterator d(s.begin(), s.end(), re, -1);
std::sregex_token_iterator end;

while (d != end) {
    *result++ = *d++;
}

}

And I fixed it like this and my problem was solved.

template
inline void split(const std::string &s, const std::regex& re, out result)
{
std::sregex_token_iterator d(s.begin(), s.end(), re, -1);
std::sregex_token_iterator end;

while (d != end) {
    *result = *d;
    result++;
    d++;
}

}

Just wanted to share in case anyone else has the same problem.
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant