CppCon 2019 has ended
Back To Schedule
Friday, September 20 • 09:00 - 10:00
What a View! Building Your Own (Lazy) Range Adaptors (part 1 of 2)

Log in to save this to your schedule, view media, leave feedback and see who's attending!

With their addition to C++20, ranges -- a revamped STL -- are going to send shockwaves through the way in which we design our software. The work from ranges gives us three broad things in C++20: redefined algorithms, concepts to assist in these algorithm definitions, and a handful of range adaptors, which are an abstraction over iterators for convenient program composition.

As Alex Stepanov and Sean Parent have said, the algorithms from the STL are only a sample of the algorithms that exist, and you're able to write your own. Range adaptors are no different: just because the adaptor you need isn't in C++20, doesn't mean that you can't write (or propose) it.

Using custom range adaptors can help you express your intentions in a much clearer manner. We'll spend some time implementing a range adaptor that isn't in the pipeline for C++20, starting from a motivating use-case, then move to how we implement the range adaptor -- including design considerations -- and finally, we'll write up a few tests to wrap everything up.

avatar for Christopher Di Bella

Christopher Di Bella

Staff Software Engineer, Codeplay Software
Christopher Di Bella is a Staff Software Engineer for Codeplay’s ComputeCpp Runtime Technology. He is a strong proponent for generic programming in C++ and C++ education. Chris was previously a software developer for Nasdaq, and a tutor for UNSW Australia’s COMP6771 Advanced C... Read More →

Friday September 20, 2019 09:00 - 10:00
Aurora C

Attendees (149)