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

String comparison for conditional breakpoint #213

Closed
GloriousPtr opened this issue May 16, 2024 · 2 comments
Closed

String comparison for conditional breakpoint #213

GloriousPtr opened this issue May 16, 2024 · 2 comments
Labels
Feature Request A request for a new feature or improvement.

Comments

@GloriousPtr
Copy link
Contributor

String comparison doesn't work in conditional breakpoints.
The way it works in visual studio is by doing strcmp() in the condition field but I think we can do better :)

@ryanfleury ryanfleury added the Feature Request A request for a new feature or improvement. label May 23, 2024
@ryanfleury
Copy link
Collaborator

This is now in dev and will be in 0.9.12 (though as I have said elsewhere, I don't recommend using dev just yet, since a few regressions are still being fixed).

The way this will work is you can use pointer comparison with a string literal in the evaluation system. In other words, this can now be evaluated:

some_ptr_in_program == "Hello, World!"

And it can be used in conditional breakpoints as well.

@GloriousPtr
Copy link
Contributor Author

can't compare with char[] (2nd entry in watch). Also, fourth entry giving false positive.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Request A request for a new feature or improvement.
Projects
None yet
Development

No branches or pull requests

2 participants