<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>Einherjar</author_name>
  <author_url>https://blog.hatena.ne.jp/Einherjar/</author_url>
  <blog_title>ProsBloom</blog_title>
  <blog_url>https://einherjar.hatenadiary.org/</blog_url>
  <categories>
    <anon>プログラム</anon>
    <anon>C言語</anon>
  </categories>
  <description>たとえばint変数の値を入れ替えるマクロを考える。初めに考えるだろうマクロはこんな感じか #define SWAP(x, y) int tmp; tmp = x; x = y; y = tmp; しかし、これだとC89準拠にならない。ブロックの途中で変数の宣言ができない制限があるためだ。よって次の段階ではこうなる。 #define SWAP(x, y) {int tmp; tmp = x; x = y; y = tmp; } これでほとんどの場合OKなのだが以下のような場合に問題になる。 if (x &gt; 0) SWAP(x, y); else printf(&quot;xは正の整数を入力してください&quot;)…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Feinherjar.hatenadiary.org%2Fentry%2F20071014%2Fp1&quot; title=&quot;マクロ関数 - ProsBloom&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2007-10-14 00:00:00</published>
  <title>マクロ関数</title>
  <type>rich</type>
  <url>https://einherjar.hatenadiary.org/entry/20071014/p1</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
