[PR #15029] Add til::property and other winrt helpers #30366

Open
opened 2026-01-31 09:40:21 +00:00 by claunia · 0 comments
Owner

Original Pull Request: https://github.com/microsoft/terminal/pull/15029

State: closed
Merged: Yes


Summary of the Pull Request

This was a fever dream I had last July. What if, instead of WINRT_PROPERTY magic macros everywhere, we had actual templated versions you could debug into.

So instead of

WINRT_PROPERTY(bool, Deleted, false);
WINRT_PROPERTY(OriginTag, Origin, OriginTag::None);
WINRT_PROPERTY(guid, Updates);

you'd do

til::property<bool> Deleted{ false };
til::property<OriginTag> Origin{ OriginTag::None };
til::property<guid> Updates;

.... and then I just kinda kept doing that. So I did that for til::event and til::forwarded_event too.

AND THEN LAST WEEK

Raymond Chen was like: "this is a good idea"

So here it is.

Validation Steps Performed

Added some simple tests.

**Original Pull Request:** https://github.com/microsoft/terminal/pull/15029 **State:** closed **Merged:** Yes --- ## Summary of the Pull Request This was a fever dream I had last July. What if, instead of `WINRT_PROPERTY` magic macros everywhere, we had actual templated versions you could debug into. So instead of ```c++ WINRT_PROPERTY(bool, Deleted, false); WINRT_PROPERTY(OriginTag, Origin, OriginTag::None); WINRT_PROPERTY(guid, Updates); ``` you'd do ```c++ til::property<bool> Deleted{ false }; til::property<OriginTag> Origin{ OriginTag::None }; til::property<guid> Updates; ``` .... and then I just kinda kept doing that. So I did that for `til::event` and `til::forwarded_event` too. **AND THEN LAST WEEK** Raymond Chen was like: ["this is a good idea"](https://devblogs.microsoft.com/oldnewthing/20230317-00/?p=107946) So here it is. ## Validation Steps Performed Added some simple tests.
claunia added the pull-request label 2026-01-31 09:40:21 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#30366