-
Notifications
You must be signed in to change notification settings - Fork 96
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
Update path2regex (again) #169
Conversation
I tested this under c++17 initially. Have reproduced the errors you've mentioned under c++14. They evidently have something to do with differences between the real optional/string_view and the nonstd versions. Will update once I figure how to get it fixed. |
Updated the path2regex code to be in line with the latest version of the javascript code, this version does not rely on std::cregex_iterator to create the matching pattern.
I just compiled it under c++14 and it seems to be working properly now. The optional-lite error somehow came about because I did |
I'm sorry, but this PR can't be accepted too because it breaks the compatibility with existing behavior:
It's a pity that you spent some of your time for code that can't be merged into RESTinio-0.6. Maybe it's better to provide a minimal and self-sufficient example that shows a problem from #166 and we'll try to modify our implementation without breaking the existing behavior? |
I did this because it's what that field is called in the original code, and it took me quite a while to understand that. Your version has
Could you give me details on this?
You can't fix it without changing it fundamentally, because I don't think it's really a problem with your code itself but rather with I am willing to keep working on this until it can be merged, but the way you manage PRs is very awkward and makes it difficult to do so, because I need to make a new PR whenever I make new changes. |
There is the output from the failed test:
|
@eao197 it appears the previous PR had some sort of weird merge issue, because the code was different from what I'd pushed to the performous fork. It should be fixed. If there are still problems with it, could you just let me know but not close the PR, so I can work to fix them?
Most odd was that optional-lite error you posted about, because I don't really know how that related to the PR, or where that issue was coming from.
Original PR description below:
Updated the path2regex code to be in line with the latest version of the javascript code, this version does not rely on std::cregex_iterator to create the matching pattern., and thus solves #166
I haven't tested it too extensively, but I did test it with some of the examples from the wiki, as well as in the context of performous, and it appears to be working as expected.
Of note: This version does not allow modifiers outside a capturing group, so for example to match anything the route would be
"(.*)"
instead of".*"