
8 Sep
2014
8 Sep
'14
9:32 a.m.
Have you ever wanted to deal with the builders for various data types in a polymorphic/overloaded fashion? I'm needing to do so and couldn't find any existing code that did so, so I decided to rectify this: http://hackage.haskell.org/package/buildable As a (very contrived) example: λ> build ((365 :: Dec Int) <| fromValue (Char7 ' ') |> (365 :: BigEndian Int16) |> (" omega=𝟂 " :: Utf8 String) |> Utf16 (LE ("hello" :: LT.Text))) :: SB.ByteString "365 \SOHm omega=\240\157\159\130 h\NULe\NULl\NULl\NULo\NUL" -- Ivan Lazar Miljenovic Ivan.Miljenovic@gmail.com http://IvanMiljenovic.wordpress.com