<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>zetamatta</author_name>
  <author_url>https://blog.hatena.ne.jp/zetamatta/</author_url>
  <blog_title>標準愚痴出力</blog_title>
  <blog_url>https://zetamatta.hatenablog.com/</blog_url>
  <categories>
    <anon>C++</anon>
  </categories>
  <description>map から map へ要素を移動するのに、unique_ptr を使いたかったが、当時使っていた VC++ 2010 か 20151 では、コンパイルエラーになってしまった。 その時は結局、shared_ptr を使って回避した。 今、gcc 11.2.0 で試してみると問題は再現しない。コンパイラの不具合でよかったのだろうか （もう手元には VC++ がないので、検証できない） #include &lt;iostream&gt; #include &lt;map&gt; #include &lt;memory&gt; #include &lt;string&gt; struct Hoge { std::string value; Hog…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fzetamatta.hatenablog.com%2Fentry%2F2023%2F02%2F28%2F104937&quot; title=&quot;古い VC++ でコンパイルエラーになったが、gcc 11.2.0 だと普通に動いてしまった unique\_ptr を使ったコード - 標準愚痴出力&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>2023-02-28 10:49:37</published>
  <title>古い VC++ でコンパイルエラーになったが、gcc 11.2.0 だと普通に動いてしまった unique\_ptr を使ったコード</title>
  <type>rich</type>
  <url>https://zetamatta.hatenablog.com/entry/2023/02/28/104937</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
