<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>tagomoris</author_name>
  <author_url>https://blog.hatena.ne.jp/tagomoris/</author_url>
  <blog_title>たごもりすメモ</blog_title>
  <blog_url>https://tagomoris.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>前にRubyでtry-with-resourcesが使いたいという話を書いてそのときにリリースしたgemもあるが、人類の安全に・便利にリソースを解放したいという欲求には際限がない。 try-with-resources は便利なんだけど欠点がないわけではなくて、リソースの確保と解放を一ヶ所でまとめてやらないとネストが深くなる。複数箇所に分けて書くならネストも2段になってしまう。 これはこれで整理されたコードを書く圧力になるので悪くない面もあるんだけど、とはいえもうちょっと自由にやりたい、いい方法は無いもんか、という話。 defer ある。Golangの defer が便利そう。defer fo…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftagomoris.hatenablog.com%2Fentry%2F2018%2F03%2F14%2F154637&quot; title=&quot;Golangの defer をRubyでも使いたい - たごもりすメモ&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>2018-03-14 15:46:37</published>
  <title>Golangの defer をRubyでも使いたい</title>
  <type>rich</type>
  <url>https://tagomoris.hatenablog.com/entry/2018/03/14/154637</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
