Small Icon in the Gutter - NOT a Breakpoint

Does anyone know the purpose of these grey-blue icons in the gutter?

Notably, they’re not breakpoints (the icon for those is larger), which can still appear normally on this line & are drawn behind this mystery icon.

The script above is nonsense, but shows a couple of the triggers for displaying the icon. Line 2 has the most common one I’ve come across – having code followed by a single line comment containing the » character.

I believe they show you that line was executed in the last run.

Run this script in debugging mode.

You’ll see that the lines that don’t execute don’t get that flag.

The ones that do execute do, and the more often they execute the bigger they get. They also change color.

use AppleScript version "2.4" -- Yosemite (10.10) or later
use scripting additions
set y to 1
set z to 0
repeat with x from 1 to 10
	if x > 11 then
		set y to 10
	else
		if x = 5 then
			repeat with y from 1 to 50
				set z to z + 1
			end repeat
		end if
	end if
end repeat

Their official name is Code Coverage symbols. You can turn them on and off, and clear them, via the commands in the Script menu.

Full details are in Script Debugger’s Help.

1 Like

The blue bubble is a “Marker”. This indicates important points within your script that should appear in the script’s table-of-contents/navigation menu:

Markers are described in the Navigation page in Script Debugger’s Help guide:

Note that the presence of two greater-than symbols (>>) or a chevron (») within a comment indicates a marker.

In your example, because you placed an «class utf8» ... expression within a comment, Script Debugger flags the comment as containing a marker.

Note that markers are distinct from code coverage indicators (circles in the script’s margin).

1 Like

Excellent – thanks Mark. :smiley:

Never knew this was a feature! Will definitely make use of it in the future.