<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>debugging | Learn C Games Programming Blog</title>
	<atom:link href="https://learncgames.com/tag/debugging/feed/" rel="self" type="application/rss+xml" />
	<link>https://learncgames.com</link>
	<description>A blog about C, programming games and my ebook(s).</description>
	<lastBuildDate>Sat, 26 Apr 2025 14:24:19 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://learncgames.com/wp-content/uploads/2020/03/cropped-favicon-32x32.png</url>
	<title>debugging | Learn C Games Programming Blog</title>
	<link>https://learncgames.com</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">181446779</site>	<item>
		<title>Debugging C/C++ and Rust with codelldb</title>
		<link>https://learncgames.com/debugging-c-c-and-rust-with-codelldb/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=debugging-c-c-and-rust-with-codelldb</link>
		
		<dc:creator><![CDATA[David]]></dc:creator>
		<pubDate>Sat, 26 Apr 2025 23:05:03 +0000</pubDate>
				<category><![CDATA[C++]]></category>
		<category><![CDATA[Debugging]]></category>
		<category><![CDATA[Rust]]></category>
		<category><![CDATA[debugging]]></category>
		<guid isPermaLink="false">https://learncgames.com/?p=3381</guid>

					<description><![CDATA[<p>As a user of Visual Studio since about VS 5, I&#8217;ve become accustomed to being able to debug. With VS Code, it&#8217;s also been easy but now that I program in C and Rust, the codelldb extension makes things very easy. You need other extensions: for Rust- the Rust Analyzer extension and for C/C++ the [&#8230;]</p>
The post <a href="https://learncgames.com/debugging-c-c-and-rust-with-codelldb/">Debugging C/C++ and Rust with codelldb</a> first appeared on <a href="https://learncgames.com">Learn C Games Programming Blog</a>.]]></description>
										<content:encoded><![CDATA[<p><img fetchpriority="high" decoding="async" class="alignleft size-full wp-image-3385" src="https://learncgames.com/wp-content/uploads/2025/04/extensions.png" alt="Extensions for C/C++" width="350" height="562" srcset="https://learncgames.com/wp-content/uploads/2025/04/extensions.png 350w, https://learncgames.com/wp-content/uploads/2025/04/extensions-187x300.png 187w" sizes="(max-width: 350px) 100vw, 350px" />As a user of Visual Studio since about VS 5, I&#8217;ve become accustomed to being able to debug. With VS Code, it&#8217;s also been easy but now that I program in C and Rust, the <strong>codelldb</strong> extension makes things very easy. You need other extensions: for Rust- the Rust Analyzer extension and for C/C++ the Microsoft C/C++ extension.</p>
<p>And for debugging for both the codelldb extension which is shown.  It uses the usual Microsoft debugging keys: F5 to start F10 to step over, F11 to step into and F9 to toggle a breakpoint.</p>
<p>Below is an example of debugging a Rust program.</p>
<p><img decoding="async" class="alignleft size-full wp-image-3386" src="https://learncgames.com/wp-content/uploads/2025/04/debuggingRust.png" alt="debugging Rust program in VS Code" width="1094" height="557" srcset="https://learncgames.com/wp-content/uploads/2025/04/debuggingRust.png 1094w, https://learncgames.com/wp-content/uploads/2025/04/debuggingRust-300x153.png 300w, https://learncgames.com/wp-content/uploads/2025/04/debuggingRust-1024x521.png 1024w, https://learncgames.com/wp-content/uploads/2025/04/debuggingRust-768x391.png 768w" sizes="(max-width: 1094px) 100vw, 1094px" /></p>The post <a href="https://learncgames.com/debugging-c-c-and-rust-with-codelldb/">Debugging C/C++ and Rust with codelldb</a> first appeared on <a href="https://learncgames.com">Learn C Games Programming Blog</a>.]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3381</post-id>	</item>
		<item>
		<title>Debugging C# on Ubuntu and you get</title>
		<link>https://learncgames.com/debugging-c-on-ubuntu-and-you-get/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=debugging-c-on-ubuntu-and-you-get</link>
		
		<dc:creator><![CDATA[David]]></dc:creator>
		<pubDate>Fri, 07 Apr 2023 23:01:33 +0000</pubDate>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Techniques]]></category>
		<category><![CDATA[debugging]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<guid isPermaLink="false">https://learncgames.com/?p=3246</guid>

					<description><![CDATA[<p>So you&#8217;re trying to debug C# code on Linux, maybe Ubuntu. You&#8217;ve installed .NET 6 or 7, you&#8217;ve built your solution in Visual Studio on your Windows PC, published it then copied the files over to the Linux box. But when you run it, you get an error &#8220;Unable to find debugger script at&#8221;. It&#8217;s [&#8230;]</p>
The post <a href="https://learncgames.com/debugging-c-on-ubuntu-and-you-get/">Debugging C# on Ubuntu and you get</a> first appeared on <a href="https://learncgames.com">Learn C Games Programming Blog</a>.]]></description>
										<content:encoded><![CDATA[<div class='__iawmlf-post-loop-links' style='display:none;' data-iawmlf-post-links='[{&quot;id&quot;:29,&quot;href&quot;:&quot;https:\/\/developercommunity.visualstudio.com\/t\/Failed-to-launch-debug-adapter-due-to-fa\/1359155&quot;,&quot;archived_href&quot;:&quot;http:\/\/web-wp.archive.org\/web\/20260206110839\/https:\/\/developercommunity.visualstudio.com\/t\/Failed-to-launch-debug-adapter-due-to-fa\/1359155&quot;,&quot;redirect_href&quot;:&quot;&quot;,&quot;checks&quot;:[{&quot;date&quot;:&quot;2026-02-06 12:35:50&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-09 15:01:05&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-12 19:49:47&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-16 18:55:07&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-20 02:01:57&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-23 16:01:17&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-27 00:17:51&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-03 00:09:08&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-06 02:18:16&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-10 04:32:06&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-13 08:50:47&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-16 15:02:52&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-20 00:37:25&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-24 00:39:09&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-28 00:36:22&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-01 03:18:28&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-04 12:42:47&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-07 20:34:45&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-11 04:24:59&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-14 12:17:08&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-17 20:10:04&quot;,&quot;http_code&quot;:503},{&quot;date&quot;:&quot;2026-04-21 04:03:01&quot;,&quot;http_code&quot;:503}],&quot;broken&quot;:false,&quot;last_checked&quot;:{&quot;date&quot;:&quot;2026-04-21 04:03:01&quot;,&quot;http_code&quot;:503},&quot;process&quot;:&quot;done&quot;}]'></div>
<p><img decoding="async" class="alignleft size-full wp-image-3249" src="https://learncgames.com/wp-content/uploads/2023/04/vs-debugger2.png" alt="vs-debugger-popup" width="420" height="190" srcset="https://learncgames.com/wp-content/uploads/2023/04/vs-debugger2.png 420w, https://learncgames.com/wp-content/uploads/2023/04/vs-debugger2-300x136.png 300w" sizes="(max-width: 420px) 100vw, 420px" /></p>
<p>So you&#8217;re trying to debug C# code on Linux, maybe Ubuntu. You&#8217;ve installed .NET 6 or 7, you&#8217;ve built your solution in Visual Studio on your Windows PC, published it then copied the files over to the Linux box. But when you run it, you get an error &#8220;Unable to find debugger script at&#8221;. It&#8217;s time to debug your Linux app from your Windows Visual Studio.</p>
<p>Now there is a <a title="Link to Developer Community for Visual Studio" href="https://developercommunity.visualstudio.com/t/Failed-to-launch-debug-adapter-due-to-fa/1359155" target="_blank" rel="nofollow noopener">Microsoft support issue</a> for this and it&#8217;s less than helpful. Read below to see how I fixed it.</p>
<p>Only, as soon as it tries to attach over SSH (with username, password, IP etc), you get this popup on the left. &#8220;Computer says no&#8221;.</p>
<p>Looking in the VS Output folder you see the text below or something similar. For whatever reason, it failed to create a hidden folder in your home folder. To fix this, all you have to do is create that folder. It&#8217;s .vs-debugger under your home folder.</p>
<p>If you&#8217;re not familiar with .folders on Linux, note that the . at the front of the name means it&#8217;s a hidden folder. A simple <strong>ls</strong> command will not reveal it. If you use the File Manager, you can click the settings in the top right and tick the Show Hidden Files. Then you can do a <strong>cd ~</strong> followed by a <strong>mkdir .vs-debugger</strong>. And View in files to confirm that it&#8217;s there.</p>
<p><img loading="lazy" decoding="async" class="alignleft size-full wp-image-3248" src="https://learncgames.com/wp-content/uploads/2023/04/vs-debugger1.png" alt="" width="641" height="144" srcset="https://learncgames.com/wp-content/uploads/2023/04/vs-debugger1.png 641w, https://learncgames.com/wp-content/uploads/2023/04/vs-debugger1-300x67.png 300w" sizes="auto, (max-width: 641px) 100vw, 641px" />Now the only pain with debugging is that the application must be running for Visual Studio to attach to it. I was debugging a utility that is run, does its business and closes. So to debug it, I added this as the first line in main() in program.cs</p>
<p>Console.ReadKey();</p>
<p>So run it, let it sit waiting for a key then attach visual studio&#8217;s debugger to your app over SSH, add your breakpoints and hit a key. Simples!</p>The post <a href="https://learncgames.com/debugging-c-on-ubuntu-and-you-get/">Debugging C# on Ubuntu and you get</a> first appeared on <a href="https://learncgames.com">Learn C Games Programming Blog</a>.]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3246</post-id>	</item>
		<item>
		<title>I do like Visual Studio Code</title>
		<link>https://learncgames.com/i-do-like-visual-studio-code/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=i-do-like-visual-studio-code</link>
		
		<dc:creator><![CDATA[David]]></dc:creator>
		<pubDate>Wed, 11 Mar 2020 00:00:56 +0000</pubDate>
				<category><![CDATA[Tools]]></category>
		<category><![CDATA[debugging]]></category>
		<category><![CDATA[IDE]]></category>
		<guid isPermaLink="false">https://learncgames.com/?p=101</guid>

					<description><![CDATA[<p>When I wrote the Windows version of the book I used Visual Studio and it was quite excellent. But Visual Studio Code (VSC), the free cross-platform IDE is also very impressive. Not only does it let you create your own extensions but you can even include debugging and visual debugging like Visual Studio. I installed [&#8230;]</p>
The post <a href="https://learncgames.com/i-do-like-visual-studio-code/">I do like Visual Studio Code</a> first appeared on <a href="https://learncgames.com">Learn C Games Programming Blog</a>.]]></description>
										<content:encoded><![CDATA[<div class='__iawmlf-post-loop-links' style='display:none;' data-iawmlf-post-links='[{&quot;id&quot;:102,&quot;href&quot;:&quot;https:\/\/marketplace.visualstudio.com\/VSCode&quot;,&quot;archived_href&quot;:&quot;http:\/\/web-wp.archive.org\/web\/20260206115959\/https:\/\/marketplace.visualstudio.com\/VSCode&quot;,&quot;redirect_href&quot;:&quot;&quot;,&quot;checks&quot;:[{&quot;date&quot;:&quot;2026-02-13 06:00:24&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-02-25 15:59:18&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-06 10:33:45&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-09 22:47:22&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-03-17 11:19:58&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-04 23:32:17&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-13 13:38:38&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-17 07:37:50&quot;,&quot;http_code&quot;:200},{&quot;date&quot;:&quot;2026-04-21 03:50:51&quot;,&quot;http_code&quot;:200}],&quot;broken&quot;:false,&quot;last_checked&quot;:{&quot;date&quot;:&quot;2026-04-21 03:50:51&quot;,&quot;http_code&quot;:200},&quot;process&quot;:&quot;done&quot;}]'></div>
<p><img loading="lazy" decoding="async" class="size-medium wp-image-107 alignleft" src="https://learncgames.com/wp-content/uploads/2020/03/vsc-marketplace-1-300x275.png" alt="Visual Studio Code Marketplace" width="300" height="275" srcset="https://learncgames.com/wp-content/uploads/2020/03/vsc-marketplace-1-300x275.png 300w, https://learncgames.com/wp-content/uploads/2020/03/vsc-marketplace-1.png 591w" sizes="auto, (max-width: 300px) 100vw, 300px" />When I wrote the Windows version of the book I used Visual Studio and it was quite excellent. But Visual Studio Code (VSC), the free cross-platform IDE is also very impressive.</p>
<p>Not only does it let you create your own extensions but you can even include debugging and visual debugging like Visual Studio.</p>
<p>I installed Clang and it&#8217;s associated debugger lldb. It is pretty powerful, The only thing that is a bit difficult with VSC is the learning curve for configuring builds, etc. With the Microsoft C/C++ extension there are four JSON files that must be configured for compiling, debugging etc.</p>
<p>The picture is from the website for the <a href="https://marketplace.visualstudio.com/vscode" target="_blank" rel="noopener noreferrer">Visual Studio code marketplace</a>. There are currently over 16,000 extensions most if not all (I haven&#8217;t checked them all!) are free and support virtually every popular programming language and probably one or two I haven&#8217;t heard of.</p>The post <a href="https://learncgames.com/i-do-like-visual-studio-code/">I do like Visual Studio Code</a> first appeared on <a href="https://learncgames.com">Learn C Games Programming Blog</a>.]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">101</post-id>	</item>
	</channel>
</rss>
