Problem with asterisk parsing when debugging a calculator code using lldb
I wrote a simple calculate.cpp file to learn debugging through lldb. When I simply run the code for multiplying two numbers using the command ./calculate 2 '*' 3, things go fine. But when I pass in the arguments as lldb calculate 2 '*' 3, the value of argc as inspected within lldb turns out to be 6 instead of 4. Why so (as far as I can understand, it is because lldb parses * to look for other files within the same folder and passes those as arguments too) and what's the fix? PS I ChatGPTed the same question and it said to use lldb calculate 2 '\*' 3. But it fails with the following message. er
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.