(For this series, I’ll assume that you know the basics of COM. If you need a refresher, I highly recommend Kenny Kerr‘s excellent Pluralsight course, The Essentials of COM.) Sooner or later, every Windows programmer has to deal with COM,…
No time, no problem
Unit tests are supposed to be deterministic. If a test is called out as being nondeterministic, you can bet that it depends on time in some way. Any app big enough and with sufficient unit tests likely has something akin…
New day, new style
I have used StyleCop for years. The project started back in the mid-2000s as an internal Microsoft tool, was released to the world in 2008, and became open source on CodePlex in 2010. As you can imagine, coding style can…
Redecorating with C++
The decorator pattern is one of the classics in the Gang of Four Design Patterns book. Let’s explore this pattern first with a C# example. This is just your average decorator, which as the code comments say, employs inheritance and…
UberQueue challenge
David Fowler tweeted: Coding challenge for you in any language. I want to see different ways of expressing this computation: The challenge was, of course, expressed in C# and what luck — that was my chosen implementation language! Before I…
Letter Boxed: Rust impl, part 4 (complete solver)
After some incremental progress in our Letter Boxed solver, we’re now ready to complete the app. Our hard-won “expertise” in Rust now makes the last several steps largely mechanical. The first set of changes produces LetterBox and Vertices structs, so…
Letter Boxed: Rust impl, part 3 (modules, trie, I/O)
Our Rust-based Letter Boxed code so far has just the core character-based data types. Today we’ll add the trie. Before we move on, we need to keep our house in order. Rather than have one massive lib.rs file, we should…
Letter Boxed: Rust impl, part 2 (panicking, hashing, parsing)
Previously we began our Rust exploration of Letter Boxed with the core St and Ch structs. Now we’ll complete their functionality. The next test on our TODO list looks like this in the C# version: We’ve already encountered our first…
Letter Boxed: Rust impl, part 1 (basics)
We’ve already set up the development environment, so let’s write some Rust code! A good place to start is with the bottom layer data structures, known as Str and Ch in the C# version. To review, Ch is an enumeration…
Letter Boxed: introducing Rust!
In the ongoing Letter Boxed solver saga, we have explored native code from the C++ angle. After all, C++ is still comfortably among the top of the close-to-the-metal programming languages (at least according to some sources). But it’s 2021 AD…