<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Preprocessor on GanniPiece Blog</title>
    <link>https://blog.gannipiece.tw/en/tags/preprocessor/</link>
    <description>Recent content in Preprocessor on GanniPiece Blog</description>
    <generator>Hugo</generator>
    <language>en</language>
    <lastBuildDate>Sat, 08 Oct 2022 16:06:04 +0000</lastBuildDate>
    <atom:link href="https://blog.gannipiece.tw/en/tags/preprocessor/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Code Expansion: Macro vs Inline Function</title>
      <link>https://blog.gannipiece.tw/en/posts/macro-vs-inline-function/</link>
      <pubDate>Sat, 08 Oct 2022 16:06:04 +0000</pubDate>
      <guid>https://blog.gannipiece.tw/en/posts/macro-vs-inline-function/</guid>
      <description>&lt;p&gt;&lt;em&gt;(the post is automatically translated by AI)&lt;/em&gt;&lt;/p&gt;
&lt;h2 id=&#34;introduction&#34;&gt;Introduction&lt;/h2&gt;
&lt;p&gt;Macros and inline functions are two techniques for code reuse and expansion. Unlike regular function calls, both avoid the overhead of subroutine push/pop operations at runtime, which can speed up execution.&lt;/p&gt;
&lt;p&gt;The key difference between them is &lt;strong&gt;when&lt;/strong&gt; the expansion happens: macros are substituted by the preprocessor before compilation, while inline functions are expanded by the compiler during compilation. However, both result in larger binary sizes compared to using regular functions, since the code is duplicated at every call site.&lt;/p&gt;</description>
    </item>
    <item>
      <title>#: The Language of the Preprocessor</title>
      <link>https://blog.gannipiece.tw/en/posts/preprocessor-language/</link>
      <pubDate>Wed, 05 Oct 2022 08:30:53 +0000</pubDate>
      <guid>https://blog.gannipiece.tw/en/posts/preprocessor-language/</guid>
      <description>The preprocessor runs before the compilation phase. It can handle conditional compilation, file inclusion, macro definitions, and more. In this article, we introduce several types of preprocessor directives, such as Conditional inclusion and Replacing text macros.</description>
    </item>
  </channel>
</rss>
