The Old New Thing

Practical development throughout the evolution of Windows.

Latest posts

Intercepting messages inside <CODE>Is­Dialog­Message</CODE>, fine-tuning the message filter
Feb 27, 2026
Post comments count 2
Post likes count 2

Intercepting messages inside Is­Dialog­Message, fine-tuning the message filter

Raymond Chen
Raymond Chen

Making sure it triggers when you need it, and not when you don't.

Intercepting messages inside <CODE>Is­Dialog­Message</CODE>, installing the message filter
Feb 26, 2026
Post comments count 1
Post likes count 2

Intercepting messages inside Is­Dialog­Message, installing the message filter

Raymond Chen
Raymond Chen

Using an <CODE>Is­Dialog­Message</CODE> extension point.

Intercepting messages before <CODE>Is­Dialog­Message</CODE> can process them
Feb 25, 2026
Post comments count 3
Post likes count 1

Intercepting messages before Is­Dialog­Message can process them

Raymond Chen
Raymond Chen

Process the message before you let <CODE>Is­Dialog­Message</CODE> see it.

Customizing the ways the dialog manager dismisses itself: Isolating the Close pathway
Feb 24, 2026
Post comments count 2
Post likes count 2

Customizing the ways the dialog manager dismisses itself: Isolating the Close pathway

Raymond Chen
Raymond Chen

Intercepting the flow in your message loop.

Customizing the ways the dialog manager dismisses itself: Detecting the ESC key, second (failed) attempt
Feb 23, 2026
Post comments count 0
Post likes count 2

Customizing the ways the dialog manager dismisses itself: Detecting the ESC key, second (failed) attempt

Raymond Chen
Raymond Chen

Sniffing the synchronous keyboard state is still not precise enough.

The 2026/2027 Seattle Symphony subscription season at a glance
Feb 20, 2026
Post comments count 0
Post likes count 0

The 2026/2027 Seattle Symphony subscription season at a glance

Raymond Chen
Raymond Chen

The pocket reference guide for 2026/2027.

Customizing the ways the dialog manager dismisses itself: Detecting the ESC key, first (failed) attempt
Feb 20, 2026
Post comments count 12
Post likes count 3

Customizing the ways the dialog manager dismisses itself: Detecting the ESC key, first (failed) attempt

Raymond Chen
Raymond Chen

Sniffing the asynchronous keyboard state.

Exploring the signals the dialog manager uses for dismissing a dialog
Feb 19, 2026
Post comments count 1
Post likes count 6

Exploring the signals the dialog manager uses for dismissing a dialog

Raymond Chen
Raymond Chen

Summarizing the flow.

Could <CODE>Write­Process­Memory</CODE> be made faster by avoiding the intermediate buffer?
Feb 18, 2026
Post comments count 3
Post likes count 2

Could Write­Process­Memory be made faster by avoiding the intermediate buffer?

Raymond Chen
Raymond Chen

I guess it could, but why bother?

Microspeak: Escrow
Feb 17, 2026
Post comments count 8
Post likes count 2

Microspeak: Escrow

Raymond Chen
Raymond Chen

Final build, final, final, final 2, ship this one.

It rather involved being on the other side of the airtight hatchway: Tricking(?) a program into reading files
Feb 16, 2026
Post comments count 10
Post likes count 2

It rather involved being on the other side of the airtight hatchway: Tricking(?) a program into reading files

Raymond Chen
Raymond Chen

Is it really a trick when reading the file is the purpose of the program?

How can I distinguish between the numeric keypad 0 and the top-row 0 in the <CODE>WM_<WBR>CHAR</CODE> message?
Feb 13, 2026
Post comments count 10
Post likes count 4

How can I distinguish between the numeric keypad 0 and the top-row 0 in the WM_CHAR message?

Raymond Chen
Raymond Chen

See if it matches the scan code.

How can I distinguish between the numeric keypad 0 and the top-row 0 in the <CODE>WM_<WBR>KEY­DOWN</CODE> message?
Feb 12, 2026
Post comments count 2
Post likes count 3

How can I distinguish between the numeric keypad 0 and the top-row 0 in the WM_KEY­DOWN message?

Raymond Chen
Raymond Chen

Check whether it is an extended key.

How do I suppress the hover effects when I put a Win32 common controls ListView in single-click mode?
Feb 11, 2026
Post comments count 0
Post likes count 4

How do I suppress the hover effects when I put a Win32 common controls ListView in single-click mode?

Raymond Chen
Raymond Chen

You can prevent the item from becoming hot-tracked.

How did Windows 95 get permission to put the Weezer video <I>Buddy Holly</I> on the CD?
Feb 10, 2026
Post comments count 11
Post likes count 6

How did Windows 95 get permission to put the Weezer video Buddy Holly on the CD?

Raymond Chen
Raymond Chen

Asking nicely, and asking a lot of people.

What should I do if a wait call reports <CODE>WAIT_<WBR>ABANDONED</CODE>?
Feb 9, 2026
Post comments count 3
Post likes count 3

What should I do if a wait call reports WAIT_ABANDONED?

Raymond Chen
Raymond Chen

It's your one chance to make amends.

How can I prevent the user from changing the widths of ListView columns in version 5 of the common controls?, part 2
Feb 6, 2026
Post comments count 1
Post likes count 3

How can I prevent the user from changing the widths of ListView columns in version 5 of the common controls?, part 2

Raymond Chen
Raymond Chen

Preventing the resize cursor from appearing.

How can I prevent the user from changing the widths of ListView columns in version 5 of the common controls?
Feb 5, 2026
Post comments count 6
Post likes count 2

How can I prevent the user from changing the widths of ListView columns in version 5 of the common controls?

Raymond Chen
Raymond Chen

Deny changes to the width.

Super Bowl LX creates an opportunity for symphonic friendly wagering
Feb 4, 2026
Post comments count 2
Post likes count 1

Super Bowl LX creates an opportunity for symphonic friendly wagering

Raymond Chen
Raymond Chen

Betting classical music.

How can I prevent the user from changing the widths of ListView columns?
Feb 4, 2026
Post comments count 3
Post likes count 2

How can I prevent the user from changing the widths of ListView columns?

Raymond Chen
Raymond Chen

You can ask the header to be non-resizing.

Some small stories about the giant satellite dish antenna that was behind Microsoft Building 11
Feb 3, 2026
Post comments count 0
Post likes count 7

Some small stories about the giant satellite dish antenna that was behind Microsoft Building 11

Raymond Chen
Raymond Chen

A little trivia.

Studying compiler error messages closely: Input file paths
Feb 2, 2026
Post comments count 5
Post likes count 2

Studying compiler error messages closely: Input file paths

Raymond Chen
Raymond Chen

Are you even compiling the correct file?

Why not store the <CODE>SAFEARRAY</CODE> reference count as a hidden allocation next to the <CODE>SAFEARRAY</CODE>?
Jan 30, 2026
Post comments count 1
Post likes count 1

Why not store the SAFEARRAY reference count as a hidden allocation next to the SAFEARRAY?

Raymond Chen
Raymond Chen

The case of "Bring your own <CODE>SAFEARRAY</CODE>."

How can I retain access to the data in a <CODE>SAFEARRAY</CODE> after my method returns?
Jan 29, 2026
Post comments count 1
Post likes count 2

How can I retain access to the data in a SAFEARRAY after my method returns?

Raymond Chen
Raymond Chen

Find a way to take ownership.

Why did I lose the data even though I called <CODE>Safe­Array­Add­Ref</CODE>?
Jan 28, 2026
Post comments count 0
Post likes count 1

Why did I lose the data even though I called Safe­Array­Add­Ref?

Raymond Chen
Raymond Chen

You have to use the original pointer, but even that won't be good enough.

A digression on the design and implementation of <CODE>Safe­Array­Add­Ref</CODE> and extending APIs in general
Jan 27, 2026
Post comments count 2
Post likes count 2

A digression on the design and implementation of Safe­Array­Add­Ref and extending APIs in general

Raymond Chen
Raymond Chen

The concerns when adding a feature to an existing API.

What’s the difference between <CODE>Safe­Array­Access­Data</CODE> and <CODE>Safe­Array­Add­Ref</CODE>?
Jan 26, 2026
Post comments count 0
Post likes count 3

What’s the difference between Safe­Array­Access­Data and Safe­Array­Add­Ref?

Raymond Chen
Raymond Chen

Two ways of preserving the data.

C++ has <CODE>scope_exit</CODE> for running code at scope exit. C# says “We have <CODE>scope_exit</CODE> at home.”
Jan 23, 2026
Post comments count 15
Post likes count 6

C++ has scope_exit for running code at scope exit. C# says “We have scope_exit at home.”

Raymond Chen
Raymond Chen

You can wrap it in an <CODE>IDisposable</CODE>.

A simple helper function for attaching a progress handler to a Windows Runtime IAsync­Action­With­Progress or IAsync­Operation­With­Progress
Jan 22, 2026
Post comments count 6
Post likes count 3

A simple helper function for attaching a progress handler to a Windows Runtime IAsync­Action­With­Progress or IAsync­Operation­With­Progress

Raymond Chen
Raymond Chen

It doesn't do much, but it saves typing.

On the proper usage of a custom Win32 dialog class
Jan 21, 2026
Post comments count 2
Post likes count 2

On the proper usage of a custom Win32 dialog class

Raymond Chen
Raymond Chen

You are replacing the window procedure, not the dialog procedure.

Microspeak: On fire, putting out fires
Jan 20, 2026
Post comments count 5
Post likes count 2

Microspeak: On fire, putting out fires

Raymond Chen
Raymond Chen

Dealing with emergencies.

What was the secret sauce that allows for a faster restart of Windows 95 if you hold the shift key?
Jan 19, 2026
Post comments count 8
Post likes count 7

What was the secret sauce that allows for a faster restart of Windows 95 if you hold the shift key?

Raymond Chen
Raymond Chen

An old flag from 16-bit Windows.

How can I get the tab index number from a dialog box control?
Jan 16, 2026
Post comments count 1
Post likes count 2

How can I get the tab index number from a dialog box control?

Raymond Chen
Raymond Chen

The tab index number is an authoring concept, not a runtime concept.

When programs assume that the system will never change, episode 4: Stealing strings
Jan 15, 2026
Post comments count 26
Post likes count 4

When programs assume that the system will never change, episode 4: Stealing strings

Raymond Chen
Raymond Chen

The strings are an implementation detail.

Clipping the focus item when looking for its on-screen location, part 3
Jan 14, 2026
Post comments count 0
Post likes count 1

Clipping the focus item when looking for its on-screen location, part 3

Raymond Chen
Raymond Chen

Finding <I>all</I> the clipping parents.

Clipping the focus item when looking for its on-screen location, part 2
Jan 13, 2026
Post comments count 1
Post likes count 2

Clipping the focus item when looking for its on-screen location, part 2

Raymond Chen
Raymond Chen

Finding the correct clipping parent.

Clipping the focus item when looking for its on-screen location
Jan 12, 2026
Post comments count 0
Post likes count 2

Clipping the focus item when looking for its on-screen location

Raymond Chen
Raymond Chen

Preventing the cursor from pointing to nothing.

Using Active Accessibility to find out where the focus item is
Jan 9, 2026
Post comments count 1
Post likes count 1

Using Active Accessibility to find out where the focus item is

Raymond Chen
Raymond Chen

Looking at child objects.

Using Active Accessibility to find out where the Windows caret is
Jan 8, 2026
Post comments count 4
Post likes count 2

Using Active Accessibility to find out where the Windows caret is

Raymond Chen
Raymond Chen

It's old and rather simple, but we like simple.

How can I find out where the Windows caret is?
Jan 7, 2026
Post comments count 1
Post likes count 1

How can I find out where the Windows caret is?

Raymond Chen
Raymond Chen

You'll have go to a larger scope.

Swapping two blocks of memory that reside inside a larger block, in constant memory, refinement
Jan 6, 2026
Post comments count 1
Post likes count 2

Swapping two blocks of memory that reside inside a larger block, in constant memory, refinement

Raymond Chen
Raymond Chen

Could do with a little less rotating.

How can you swap two non-adjacent blocks of memory using only forward iterators?
Jan 5, 2026
Post comments count 1
Post likes count 3

How can you swap two non-adjacent blocks of memory using only forward iterators?

Raymond Chen
Raymond Chen

Applying the rotation trick to our new problem.

How can you swap two adjacent blocks of memory using only forward iterators?
Jan 2, 2026
Post comments count 0
Post likes count 2

How can you swap two adjacent blocks of memory using only forward iterators?

Raymond Chen
Raymond Chen

A different algorithm, employing a different kind of cleverness.

Swapping two blocks of memory that reside inside a larger block, in constant memory
Jan 1, 2026
Post comments count 10
Post likes count 2

Swapping two blocks of memory that reside inside a larger block, in constant memory

Raymond Chen
Raymond Chen

A variation on the constant-memory rotation.

2025 year-end link clearance
Dec 31, 2025
Post comments count 5
Post likes count 2

2025 year-end link clearance

Raymond Chen
Raymond Chen

Another year gets relegated to history.

Understanding and mitigating a stack overflow in our task sequencer
Dec 31, 2025
Post comments count 1
Post likes count 2

Understanding and mitigating a stack overflow in our task sequencer

Raymond Chen
Raymond Chen

The recurring problem of synchronous resumption.

Additional notes on color-keyed overlays as a way of doing smooth video rendering
Dec 30, 2025
Post comments count 6
Post likes count 3

Additional notes on color-keyed overlays as a way of doing smooth video rendering

Raymond Chen
Raymond Chen

Choosing the color-key and other brief discussions.

The Gävle Goat (Gävlebocken) succumbs in 2025 to a new menace
Dec 29, 2025
Post comments count 3
Post likes count 2

The Gävle Goat (Gävlebocken) succumbs in 2025 to a new menace

Raymond Chen
Raymond Chen

You could blow me over.

How can I detect that the system is running low on memory? Or that my job is running low on memory?
Dec 29, 2025
Post comments count 3
Post likes count 2

How can I detect that the system is running low on memory? Or that my job is running low on memory?

Raymond Chen
Raymond Chen

You can register for a memory notification.

Why are we worried about memory access semantics? Full barriers should be enough for anybody
Dec 26, 2025
Post comments count 7
Post likes count 4

Why are we worried about memory access semantics? Full barriers should be enough for anybody

Raymond Chen
Raymond Chen

You have to find new ways of going faster.

Reading the fine print, episode 4: Holiday promotions
Dec 25, 2025
Post comments count 4
Post likes count 3

Reading the fine print, episode 4: Holiday promotions

Raymond Chen
Raymond Chen

Checking those validity dates.

Why is the last letter of my string not making it to the clipboard?
Dec 25, 2025
Post comments count 0
Post likes count 3

Why is the last letter of my string not making it to the clipboard?

Raymond Chen
Raymond Chen

The struggle for null termination.

Why does my <KBD>Ctrl</KBD>+<KBD>M</KBD> accelerator key activate when I press the <KBD>Enter</KBD> key?
Dec 24, 2025
Post comments count 1
Post likes count 5

Why does my Ctrl+M accelerator key activate when I press the Enter key?

Raymond Chen
Raymond Chen

Understanding the difference between keys and characters for accelerators.

When irate product support customers demand to speak to Bill Gates
Dec 23, 2025
Post comments count 4
Post likes count 5

When irate product support customers demand to speak to Bill Gates

Raymond Chen
Raymond Chen

So transfer them to his office, or so it seems.

All the other cool languages have <CODE>try</CODE>…<CODE>finally</CODE>. C++ says “We have <CODE>try</CODE>…<CODE>finally</CODE> at home.”
Dec 22, 2025
Post comments count 27
Post likes count 9

All the other cool languages have tryfinally. C++ says “We have tryfinally at home.”

Raymond Chen
Raymond Chen

The destructor serves as the "finally".

A shortcut gives me a weird path for a program shortcut that doesn’t point to the executable, so what is it?
Dec 19, 2025
Post comments count 9
Post likes count 3

A shortcut gives me a weird path for a program shortcut that doesn’t point to the executable, so what is it?

Raymond Chen
Raymond Chen

It's a placeholder because the shortcut is to an MSI application.

Concluding thoughts on our deep dive into Windows clipboard text conversion
Dec 18, 2025
Post comments count 10
Post likes count 4

Concluding thoughts on our deep dive into Windows clipboard text conversion

Raymond Chen
Raymond Chen

Stick to Unicode and you'll be fine.

Deducing the consequences of Windows clipboard text formats on UTF-8
Dec 17, 2025
Post comments count 3
Post likes count 4

Deducing the consequences of Windows clipboard text formats on UTF-8

Raymond Chen
Raymond Chen

Working out the implications.

Why is the Windows clipboard taking the scenic route when converting from <CODE>CF_<WBR>TEXT</CODE> to <CODE>CF_<WBR>OEM­TEXT</CODE>?
Dec 16, 2025
Post comments count 3
Post likes count 2

Why is the Windows clipboard taking the scenic route when converting from CF_TEXT to CF_OEM­TEXT?

Raymond Chen
Raymond Chen

Something is forcing it down an alternate path.

Misunderstanding what the Cricket Celebration Bowl is
Dec 15, 2025
Post comments count 3
Post likes count 1

Misunderstanding what the Cricket Celebration Bowl is

Raymond Chen
Raymond Chen

Apparently, not a bowl of crickets.

The Windows clipboard automatic text conversion algorithm is path-dependent
Dec 15, 2025
Post comments count 1
Post likes count 4

The Windows clipboard automatic text conversion algorithm is path-dependent

Raymond Chen
Raymond Chen

When the journey is not half of the fun.

Resolving an ambiguity in the Windows clipboard automated text conversion table
Dec 12, 2025
Post comments count 8
Post likes count 3

Resolving an ambiguity in the Windows clipboard automated text conversion table

Raymond Chen
Raymond Chen

Who goes first?

Studying the various locale mismatch scenarios in Windows clipboard text format synthesis
Dec 11, 2025
Post comments count 11
Post likes count 3

Studying the various locale mismatch scenarios in Windows clipboard text format synthesis

Raymond Chen
Raymond Chen

If they don't match, then the 8-bit strings are basically broken already.

How does Windows synthesize the <CODE>CF_<WBR>LOCALE</CODE> clipboard format?
Dec 10, 2025
Post comments count 1
Post likes count 1

How does Windows synthesize the CF_LOCALE clipboard format?

Raymond Chen
Raymond Chen

Getting it from a place that might have been obvious in the past, but maybe not today.

How does Windows synthesize <CODE>CF_<WBR>UNICODE­TEXT</CODE> from <CODE>CF_<WBR>TEXT</CODE> and vice versa?
Dec 9, 2025
Post comments count 2
Post likes count 2

How does Windows synthesize CF_UNICODE­TEXT from CF_TEXT and vice versa?

Raymond Chen
Raymond Chen

Let's ask the locale.

How does Windows synthesize <CODE>CF_<WBR>OEM­TEXT</CODE> from <CODE>CF_<WBR>TEXT</CODE> and vice versa?
Dec 8, 2025
Post comments count 11
Post likes count 3

How does Windows synthesize CF_OEM­TEXT from CF_TEXT and vice versa?

Raymond Chen
Raymond Chen

Starting with the easy case, or at least it looks easy.

How can my process read its own standard output?
Dec 5, 2025
Post comments count 11
Post likes count 3

How can my process read its own standard output?

Raymond Chen
Raymond Chen

You'll have to trick yourself before anybody notices, which may not be possible.

How can I read the standard output of an already-running process?
Dec 4, 2025
Post comments count 5
Post likes count 1

How can I read the standard output of an already-running process?

Raymond Chen
Raymond Chen

You can't. You'll have to do it before the process starts.

How do I check whether the user has permission to create files in a directory?
Dec 3, 2025
Post comments count 6
Post likes count 5

How do I check whether the user has permission to create files in a directory?

Raymond Chen
Raymond Chen

Request the directory security attributes that correspond to your proposed operation.

Microspeak: Big rocks
Dec 2, 2025
Post comments count 3
Post likes count 2

Microspeak: Big rocks

Raymond Chen
Raymond Chen

The large obstacles.

How do I get my edit control text to be autoselected when I choose it to be the default focus in my dialog?
Dec 1, 2025
Post comments count 0
Post likes count 2

How do I get my edit control text to be autoselected when I choose it to be the default focus in my dialog?

Raymond Chen
Raymond Chen

Remembering some old APIs.

How can I have a Win32 drop-down combo box with a read-only edit control?
Nov 28, 2025
Post comments count 8
Post likes count 5

How can I have a Win32 drop-down combo box with a read-only edit control?

Raymond Chen
Raymond Chen

You can ask for its handle and mark it read-only.

Message-only windows are for messaging, not as a convenient victim for hosting UI
Nov 27, 2025
Post comments count 3
Post likes count 5

Message-only windows are for messaging, not as a convenient victim for hosting UI

Raymond Chen
Raymond Chen

If you want to host UI, use a real window (possibly hidden).

At what point in the Windows development cycle is it too late to change the text of a translatable string?
Nov 26, 2025
Post comments count 9
Post likes count 2

At what point in the Windows development cycle is it too late to change the text of a translatable string?

Raymond Chen
Raymond Chen

The translation team sets the deadline.

The apocryphal origins of the Hot Dog Stand color scheme
Nov 25, 2025
Post comments count 7
Post likes count 5

The apocryphal origins of the Hot Dog Stand color scheme

Raymond Chen
Raymond Chen

Challenge accepted.

Why does XAML break down when I have an element that is half a billion pixels tall?
Nov 24, 2025
Post comments count 5
Post likes count 4

Why does XAML break down when I have an element that is half a billion pixels tall?

Raymond Chen
Raymond Chen

You've far exceeded the design goals and have even exceeded the expressive ability of a float.

Maybe somebody can explain to me how weak references solve the ODR problem
Nov 21, 2025
Post comments count 6
Post likes count 2

Maybe somebody can explain to me how weak references solve the ODR problem

Raymond Chen
Raymond Chen

I don't see it.

In the commit-on-demand pattern, what happens if an access violation straddles multiple pages?
Nov 20, 2025
Post comments count 11
Post likes count 3

In the commit-on-demand pattern, what happens if an access violation straddles multiple pages?

Raymond Chen
Raymond Chen

The access violation exceptions will continue until commit improves.

Is <CODE>Write­Process­Memory</CODE> faster than shared memory for transferring data between two processes?
Nov 19, 2025
Post comments count 3
Post likes count 8

Is Write­Process­Memory faster than shared memory for transferring data between two processes?

Raymond Chen
Raymond Chen

Shared memory is the copy-free solution.

Microspeak: Little-r
Nov 18, 2025
Post comments count 1
Post likes count 5

Microspeak: Little-r

Raymond Chen
Raymond Chen

Harkening back to a very old mail program.

How can I detect that Windows is running in S-Mode, redux
Nov 17, 2025
Post comments count 21
Post likes count 3

How can I detect that Windows is running in S-Mode, redux

Raymond Chen
Raymond Chen

Doing it on hard mode.

I can use <CODE>WM_<WBR>COPY<WBR>DATA</CODE> to send a block of data to another window, but how does it send data back?
Nov 14, 2025
Post comments count 9
Post likes count 3

I can use WM_COPYDATA to send a block of data to another window, but how does it send data back?

Raymond Chen
Raymond Chen

They can send it back with their own <CODE>WM_<WBR>COPY­DATA</CODE> message, or they can put it in an agreed-upon shared location.

Could we use CTAD to simplify the use of WRL’s Callback function?
Nov 13, 2025
Post comments count 4
Post likes count 2

Could we use CTAD to simplify the use of WRL’s Callback function?

Raymond Chen
Raymond Chen

Not directly, but maybe indirectly.

Non-recursively deleting a binary tree in constant space: Rotating the tree
Nov 12, 2025
Post comments count 5
Post likes count 6

Non-recursively deleting a binary tree in constant space: Rotating the tree

Raymond Chen
Raymond Chen

Preserving in-order while linearizing.

Behind the scenes on how Windows 95 application compatibility patched broken programs
Nov 11, 2025
Post comments count 7
Post likes count 5

Behind the scenes on how Windows 95 application compatibility patched broken programs

Raymond Chen
Raymond Chen

Replacing bytes with the greatest of care.

How did Windows 3.1 distinguish two different programs that happened to share the same executable name?
Nov 10, 2025
Post comments count 0
Post likes count 2

How did Windows 3.1 distinguish two different programs that happened to share the same executable name?

Raymond Chen
Raymond Chen

The trouble with disambiguation.

Non-recursively deleting a binary tree in constant space: Restructuring the tree
Nov 7, 2025
Post comments count 3
Post likes count 1

Non-recursively deleting a binary tree in constant space: Restructuring the tree

Raymond Chen
Raymond Chen

Changing the tree structure to make it easier to delete.

Non-recursively deleting a binary tree in constant space: Synthesizing the parent pointer
Nov 6, 2025
Post comments count 3
Post likes count 1

Non-recursively deleting a binary tree in constant space: Synthesizing the parent pointer

Raymond Chen
Raymond Chen

Making one as you go.

Non-recursively deleting a binary tree in constant space: Traversal with parent pointers
Nov 5, 2025
Post comments count 11
Post likes count 2

Non-recursively deleting a binary tree in constant space: Traversal with parent pointers

Raymond Chen
Raymond Chen

First assume that you have a parent pointer.

The Microsoft SoftCard for the Apple II: Getting two processors to share the same memory
Nov 4, 2025
Post comments count 4
Post likes count 3

The Microsoft SoftCard for the Apple II: Getting two processors to share the same memory

Raymond Chen
Raymond Chen

Reportedly Microsoft's first hardware product.

Why does <CODE>SHFormat­Date­Time</CODE> take an unaligned <CODE>FILETIME</CODE>?
Nov 3, 2025
Post comments count 3
Post likes count 2

Why does SHFormat­Date­Time take an unaligned FILETIME?

Raymond Chen
Raymond Chen

Designed for its original use case.

Microspeak: turn into a pumpkin
Oct 31, 2025
Post comments count 4
Post likes count 1

Microspeak: turn into a pumpkin

Raymond Chen
Raymond Chen

To disappear, such as for the year-end holidays.

Trying to build a XAML tree in code throws a “No installed components were detected” exception
Oct 30, 2025
Post comments count 8
Post likes count 3

Trying to build a XAML tree in code throws a “No installed components were detected” exception

Raymond Chen
Raymond Chen

An unfortunate error code collision, but the explanatory text leads the way.

What to do when you have a crash in the runtime control flow guard check
Oct 29, 2025
Post comments count 2
Post likes count 2

What to do when you have a crash in the runtime control flow guard check

Raymond Chen
Raymond Chen

You don't have to understand it, but you should be able to extract data from it.

How did the Windows 95 user interface code get brought to the Windows NT code base?
Oct 28, 2025
Post comments count 18
Post likes count 10

How did the Windows 95 user interface code get brought to the Windows NT code base?

Raymond Chen
Raymond Chen

Ported bit by bit.

Dubious security vulnerability: Denial of service by loading a very large file
Oct 27, 2025
Post comments count 11
Post likes count 5

Dubious security vulnerability: Denial of service by loading a very large file

Raymond Chen
Raymond Chen

I mean, it's what you asked it to do.

The early history of the Windows Runtime PropertyValue and why there is a PropertyType.Inspectable that is never used
Oct 24, 2025
Post comments count 0
Post likes count 2

The early history of the Windows Runtime PropertyValue and why there is a PropertyType.Inspectable that is never used

Raymond Chen
Raymond Chen

It used to be there because PropertyValue started out as the fundamental variant type before shifting focus to being the fundamental boxed type.

Windows Runtime design principle: Properties can be set in any order
Oct 23, 2025
Post comments count 0
Post likes count 3

Windows Runtime design principle: Properties can be set in any order

Raymond Chen
Raymond Chen

If all you're doing is setting properties, you can do it any way you like.

What makes <CODE>cheap_<WBR>steady_<WBR>clock</CODE> faster than <CODE>std::<WBR>chrono::<WBR>high_<WBR>resolution_<WBR>clock</CODE>?
Oct 22, 2025
Post comments count 7
Post likes count 3

What makes cheap_steady_clock faster than std::chrono::high_resolution_clock?

Raymond Chen
Raymond Chen

It's quite a bit faster, though maybe you don't care.