This event has ended. View the official site or create your own event → Check it out
This event has ended. Create your own
View analytic
Wednesday, September 23 • 2:00pm - 3:00pm
Transducers: generalized, composable and functional transformations of sequential inputs, from Clojure to C++

Log in to save this to your schedule and see who's attending!

Transducers allow to express transformations on sequential inputs (like std::transform, std::filter, most of boost::range::adators [4] and more) in a way that is independent of the input source. They are simple high order functions agnostic of the notion of iterator or collection and can be combined by simple function composition. They can later be applied eagerly or lazily over iterators, but most interestingly, also to other kinds of "reactive" sources, like networked streams, inter-process channels or reactive observables (e.g. RxCpp [3]). Not only they provide an elegant decoupling between the "what" and the "how" and higher level of reuse, their implementation is often simpler and and more performant than similar boost::range adaptors.

Transducers were introduced in Clojure by Rich Hickey [2]. At Ableton we implemented them in C++ and released them as part of our Open Source modern C++ toolkit: Atria [1]. Our implementation introduces innovations of its own, like implementing state-full transducers without mutation, enabling further safety and reusability. We also use Eric Niebler's technique [5] to describe and check its concepts in standard compliant C++11.

In this session we will introduce the concept of transducers and how they can be implemented in modern C++. We will also cover some of the most interesting use-cases.

[1] https://github.com/AbletonAG/atria
[2] http://clojure.org/transducers
[3] https://github.com/Reactive-Extensions/RxCpp
[4] http://www.boost.org/doc/libs/1_58_0/libs/range/doc/html/range/reference/adaptors.html
[5] http://ericniebler.com/2013/11/23/concept-checking-in-c11/

avatar for Juan Pedro Bolívar Puente

Juan Pedro Bolívar Puente

Software Engineer, Ableton
Juanpe is a Spanish software engineer currently based in Berlin, Germany. Since 2011 he works for Ableton, where he has helped building novel musical platforms like Push and Live and where he coordinates the "Open Source Guild" helping the adoption and contribution to FLOSS. He is most experienced in C++ and Python and likes tinkering with languages like Haskell or Clojure. He is an advocate for "modern C++" and pushes for adoption of... Read More →

Wednesday September 23, 2015 2:00pm - 3:00pm
Six (406) Meydenbauer Center