News for hackers. Stuff that matters.
Re:Elevate your C programming skills by exploring the SQLite... by minipci1321 on Sunday July 09, 2017 @09:07AM (#14729567)
When the 'return' statement is put on the same line as the parent 'if' statement, setting a breakpoint on returning requires dealing with the assembly code and hex values (identifying the instruction that implements the return (could be a ret or a jump), then using its address to set the breakpoint.

When the return statement is kept on its own line, this is much easier.

Re:Elevate your C programming skills by exploring the SQLite... by pjmlp on Sunday July 09, 2017 @11:13AM (#14730075)
Or using advanced GUI debuggers that allow middle statement breakpoints.
Re:Elevate your C programming skills by exploring the SQLite... by to3m on Sunday July 09, 2017 @11:31AM (#14730160)
Which debuggers for C or C++ do this, and which compilers do they work with?
Re:Elevate your C programming skills by exploring the SQLite... by pjmlp on Sunday July 09, 2017 @11:44AM (#14730247)
Visual C++, if I am not mistaken it was introduced on VS 2015.
Re:Elevate your C programming skills by exploring the SQLite... by to3m on Sunday July 09, 2017 @04:15PM (#14731462)
C/C++ breakpoints still appear to be line-based in VS2017. (C# breakpoints have been statement-based for a long time...)
Re:Elevate your C programming skills by exploring the SQLite... by pjmlp on Sunday July 09, 2017 @04:49PM (#14731592)
I see, my failure then.

When on VS, I spend most of my time on the .NET side, so I thought it was on the C++ side as well.