2012 in Review

Here is an overview of the things that I’ve done in 2012. Codexpert Revamped The main site for the Romanian C++ community has a brand new, modern look (all built with HTML5), making things easier to find. We also now feature a blog in English, which is intended to replace the old article section. codexpert.ro…

cpplinq: set operators

In the previous posts I introduced cpplinq, a C++ template library that provides .NET-like query operators for sequences of objects in C++11. In this third installment I will discuss the set operators the library provides. There are four set operators: distinct, union_with (called so because union is a keyword in C++), intersect_with (suffix _with is…

cpplinq: range generators and conversion operators

In my previous post I introduced cpplinq, a C++ template library that provides .NET-like query operators for sequences of objects in C++11. In this second installment I will discuss about two things: range generators and range conversion operators. These two sets of operators are ubiquitous in queries. Range generators A range generator builds an object…

cpplinq: An introduction

cpplinq is a C++ template library that provides .NET-like query operators for sequences of objects in C++11. cpplinq is an open-source library that works both with VC++ compilers (2010 and 2012) and gcc (4.7.0 is the version used for unit tests). The library supports most of the .NET query operators and is extendable with additional…

How to Determine What Process Loaded a DLL

Trying to figure out in which process a particular DLL is currently loaded, I have found two solutions (perhaps there are more). Solution 1: tasklist.exe

Solution 2: listdlls.exe (from sysinternals)

It might be that listdlls is more reliable than tasklist. I have ran into cases when tasklist failed to list processes that had…

T4 Lessons Learned

Working with T4 recently I learned a couple of valuable lessons I’d like to share. Lesson 1: Template Language One of the parameters of the language directive is the language, which specifies the language used in the code blocks of the template. Two languages are specified, C# and VB.

However, any attempts to use…

Great Artists Steal

So Apple won an important battle with Samsung (in a US court where a juror said it was clear to the jury after the first day of the trial that Samsung stole ideas from Apple, which made the rest of the one year long trial moot). Apple accused Samsung of stealing. And it’s probably not…

A tale of two flags: DS_CONTROL and WS_EX_CONTROLPARENT

I recently ran into problems with an MFC application that was hosting some Windows Form user control in a modal dialog; the application hanged after it lost focus. The problem was the window received WM_GETDLGCODE message in an infinite loop making it impossible to handle anything else. After a lot of digging, I found that…

Debugging Tools for Windows 7

Windows 8 RTM is not ready yet, but lots of things have been updated already with regard to the new version of the OS. Among them the download page for Debugging Tools for Windows. Here a screenshot from the page. Notice the following paragraph: There are certain rare circumstances in which you might need to…