Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

icons shown in left margin of IDE during debugging

During debugging, I see these two symbols (shown in green rectangles). Can someone help me understand what does these indicate?

enter image description here

like image 900
paul deter Avatar asked Dec 16 '14 15:12

paul deter


People also ask

How to debug each line in Visual Studio?

When you are editing code (rather than paused in the debugger), right-click a line of code in your app and choose Run to Cursor (or press Ctrl to F10). This command starts debugging and sets a temporary breakpoint on the current line of code.

Does Visual Studio have a debugger?

The Visual Studio debugger can help you navigate through code to inspect the state of an app and show its execution flow, which is also known as code stepping. You can use keyboard shortcuts, debug commands, breakpoints, and other features to quickly get to the code you want to examine.

How to run line by line in Visual Studio?

Click the Debug | Step Into menu item or press the F11 key to step into any property or method for debugging. You can then continue the line by line execution by pressing F10 or continue ... Get Mastering Visual Studio 2017 now with the O'Reilly learning platform.


1 Answers

This is used to represent the presence of threads at the current statement of the debugger. It allows you to determine which thread is active for the debugger.

For example, when my cursor is on the line Thread.Sleep(10) in this pointless example, I can choose which worker thread I am interested in (and set breakpoints by its process ID):

Thread example

Here I can see each of the worker threads that are currently active, and that I am currently stepping through the worker thread with the ID 28468. I can also flag threads easily or try to move the cursor to a different thread where possible.

Note that you will only see the thread icons if you've enabled "Show Threads in Source" on the debugger toolbar.

Show Threads in Source

like image 84
grovesNL Avatar answered Sep 25 '22 07:09

grovesNL