<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>hiratara</author_name>
  <author_url>https://blog.hatena.ne.jp/hiratara/</author_url>
  <blog_title>Pixel Pedals of Tomakomai</blog_title>
  <blog_url>https://hiratara.hatenadiary.jp/</blog_url>
  <categories>
    <anon>技術</anon>
  </categories>
  <description>Rust には整数の primitive 型が多数あるが、どの型でもよしなに計算してくれる関数を書きたくなる。四則演算子を表す trait はあるのだが、細かく分かれているので指定するのが大変である。 use std::fmt::Display; use std::ops::{AddAssign, Mul, MulAssign}; fn execute&lt;T&gt;(mut x: T, y: T) where T: Display + Copy + MulAssign + Mul&lt;Output = T&gt; + AddAssign, { println!(&quot;x={}, y={}&quot;, x, y); x *=…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fhiratara.hatenadiary.jp%2Fentry%2F2023%2F03%2F25%2F145242&quot; title=&quot;traitのaliasを作る ～ associated typeを添えて - Pixel Pedals of Tomakomai&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-03-25 14:52:42</published>
  <title>traitのaliasを作る ～ associated typeを添えて</title>
  <type>rich</type>
  <url>https://hiratara.hatenadiary.jp/entry/2023/03/25/145242</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
