{"id":106174,"date":"2022-01-18T07:00:00","date_gmt":"2022-01-18T15:00:00","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/oldnewthing\/?p=106174"},"modified":"2022-01-17T17:14:46","modified_gmt":"2022-01-18T01:14:46","slug":"20220118-00","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/oldnewthing\/20220118-00\/?p=106174","title":{"rendered":"How to write like Raymond: The typing-saver"},"content":{"rendered":"<p>Here&#8217;s another installment in the extremely sporadic series on <i>How to write like Raymond<\/i>.<\/p>\n<p>Last time, I discussed how <a title=\"C# and C++ type aliases and their consequences\" href=\"https:\/\/devblogs.microsoft.com\/oldnewthing\/20220117-00\/?p=106167\"> the <code>using<\/code> statement can be used to create type aliases in C# and C++<\/a>. The aliases are not types in their own right; they just let you refer to another type in a more convenient way.<\/p>\n<p>The nickname I have for things like type aliases is <i>typing-saver<\/i>.<\/p>\n<p>In the git source control system, a lightweight tag is just a typing-saver for a commit hash. Tags are not version-controlled, you can&#8217;t merge them, you can&#8217;t do anything with them except share them with others. They&#8217;re just a sticky-note with a hash written on it.<\/p>\n<p>In the Perforce source control system, a branch is just a typing-saver for an integration. Although people casually talk about branches to refer to the set of files on the right-hand side of the branch specification, the branch specification itself is used just for describing the relationship between two sets of files; it is not the files themselves. Although it is common for this relationship to be a direct mapping between trees, a branch specification could in principle establishes relationships between files scattered all over the depot.<\/p>\n<p>So if you want to write like me, pull out the phrase &#8220;typing-saver&#8221; whenever you talk about things that allow you to type something short instead of something longer, but which doesn&#8217;t add any features beyond that.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>One of my little catch phrases.<\/p>\n","protected":false},"author":1069,"featured_media":111744,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[103],"class_list":["post-106174","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-oldnewthing","tag-non-computer"],"acf":[],"blog_post_summary":"<p>One of my little catch phrases.<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/106174","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/users\/1069"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/comments?post=106174"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/106174\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media\/111744"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media?parent=106174"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/categories?post=106174"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/tags?post=106174"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}