<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>qnighy</author_name>
  <author_url>https://blog.hatena.ne.jp/qnighy/</author_url>
  <blog_title>簡潔なQ</blog_title>
  <blog_url>https://qnighy.hatenablog.com/</blog_url>
  <categories>
    <anon>Rust</anon>
  </categories>
  <description>概要: Rustの impl が定義できる型にはコヒーレンスと呼ばれる制限がある。これについて説明する。なお、この記事では特殊化がない前提で説明する。 コヒーレンス初心者のための概説 以下のように impl が重複していたり、自分のところ以外の型の impl を定義しようとするとエラーになる場合がある。これをコヒーレンスという。 struct A; // overlap rule 違反 impl A { fn f(x: i32) {} } impl A { fn f(x: i8) {} } // orphan rule 違反 impl Option&lt;A&gt; { } コヒーレンスの目的 コヒーレン…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fqnighy.hatenablog.com%2Fentry%2F2017%2F07%2F20%2F220000&quot; title=&quot;Rustのコヒーレンス - 簡潔なQ&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>2017-07-20 22:00:00</published>
  <title>Rustのコヒーレンス</title>
  <type>rich</type>
  <url>https://qnighy.hatenablog.com/entry/2017/07/20/220000</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
