-
Notifications
You must be signed in to change notification settings - Fork 120
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
Node creation bug where implicit conversion happens between type std::string and double #449
Comments
@ZigRazor i hope the PRs can pass through quickly. I would love to work on these new issues as well the travelling salesman problem as well seeing that i'm using it for my company |
I give the max priority to this bug, if you want to correct it you are welcome! |
Hi. |
Regarding the issue, the problem is that when passing "0" it interprets it as a nullptr, so it creates an empty string, which of course seg faults. |
This is what you get compiling with C++23. |
ok, we can add this check? |
Yep, should be a quick one. |
Hi, Can I work on this issue if not resolved yet |
Yes thank you :) |
Hi @sbaldu What should I do after checking the null? |
A check for I have marked it as explicit (only) in PR #484 . |
Describe the bug
The bug happens where user writes
The library accepts this as valid and it will pass compile time. But then when it times to run the actual code, this happens:
I suggest adding the explicit keyword to avoid conversion from double to std::string
This happens when user's IDE might not warn them that there is an implicit conversion and since they thought that templated type std::string is for the first parameter.
The text was updated successfully, but these errors were encountered: