The Old New Thing

Practical development throughout the evolution of Windows.

Latest posts

To some people, time zones are just a fancy way of sounding important, episode 2
How can I choose a different C++ constructor at runtime?
Mar 6, 2025
3
0

How can I choose a different C++ constructor at runtime?

Raymond Chen
Raymond Chen

Make somebody else do it, and then use copy elision.

I tried to subscribe to a C++/WinRT event, but my callback was never called
Mar 5, 2025
0
1

I tried to subscribe to a C++/WinRT event, but my callback was never called

Raymond Chen
Raymond Chen

Check how you registered your event handler.

Microspeak: Respin
Mar 4, 2025
2
2

Microspeak: Respin

Raymond Chen
Raymond Chen

Spin it up again, baby.

Lexically scoped functions accessing parent locals: The display
Mar 3, 2025
1
2

Lexically scoped functions accessing parent locals: The display

Raymond Chen
Raymond Chen

Using a well-known location instead of copying frame pointers.

C++/WinRT implementation inheritance: Notes on <CODE>winrt::implements</CODE>, part 8
Feb 28, 2025
1
0

C++/WinRT implementation inheritance: Notes on winrt::implements, part 8

Raymond Chen
Raymond Chen

Comparing the options.

C++/WinRT implementation inheritance: Notes on <CODE>winrt::implements</CODE>, part 7
Feb 27, 2025
0
0

C++/WinRT implementation inheritance: Notes on winrt::implements, part 7

Raymond Chen
Raymond Chen

Inheritance without involving winrt::implements at all.

C++/WinRT implementation inheritance: Notes on <CODE>winrt::implements</CODE>, part 6
Feb 26, 2025
0
1

C++/WinRT implementation inheritance: Notes on winrt::implements, part 6

Raymond Chen
Raymond Chen

Using CRTP to delegate the method.

C++/WinRT implementation inheritance: Notes on <CODE>winrt::implements</CODE>, part 5
Feb 25, 2025
0
0

C++/WinRT implementation inheritance: Notes on winrt::implements, part 5

Raymond Chen
Raymond Chen

When the base class isn't self-contained.