{"url":"https://sirocco.hatenadiary.org/entry/20110302/1299029239","image_url":null,"description":"Real World Haskell 10.5.3 \u300c\u67d4\u8edf\u306a\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u300d\u306b Either \u578b\u306b\u95a2\u6570\u3092\u9069\u7528\u3059\u308b\u4f8b\u304c\u3042\u308a\u307e\u3057\u305f\u3002 Haskell 98\u3067\u306f\u51fa\u6765\u306a\u304f\u3066\u3001GHC \u3067 {-# LANGUAGE FlexibleInstances #-} \u3092\u6307\u5b9a\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 \u578b\u30d1\u30e9\u30e1\u30fc\u30bf\u304c\uff11\u3064\u306e Either \u578b Functor \u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3002 {-# LANGUAGE FlexibleInstances #-} instance Functor (Either Int) where fmap _ (Left n) = Left n fmap f (Right r) = Right (f r) \u2026","version":"1.0","type":"rich","blog_title":"sirocco \u306e\u66f8\u3044\u3066\u3082\u3059\u3050\u306b\u5fd8\u308c\u308b\u30e1\u30e2","provider_name":"Hatena Blog","height":"190","blog_url":"https://sirocco.hatenadiary.org/","author_name":"sirocco","provider_url":"https://hatena.blog","title":"Either \u578b\u306b\u95a2\u6570\u3092\u9069\u7528\u3059\u308b\u3002","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fsirocco.hatenadiary.org%2Fentry%2F20110302%2F1299029239\" title=\"Either \u578b\u306b\u95a2\u6570\u3092\u9069\u7528\u3059\u308b\u3002 - sirocco \u306e\u66f8\u3044\u3066\u3082\u3059\u3050\u306b\u5fd8\u308c\u308b\u30e1\u30e2\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","categories":["Haskell"],"author_url":"https://blog.hatena.ne.jp/sirocco/","published":"2011-03-02 10:27:19","width":"100%"}