BFPG Monthly Meetup - YLJ Practice Run Edition

Brisbane Functional Programming Group (BFPG)
Brisbane Functional Programming Group (BFPG)
Public group

Data61/CSIRO Fortitude Valley

Level 2, T C Beirne Centre, 315 Brunswick Street, Fortitude Valley 4006 QLD · Brisbane

How to find us

Head into the TCB laneway and look for the Precinct lifts. Take them to level 2 and walk towards Reception and the Kitchen. Call ben on 0488145427 if you are stuck.

Location image of event venue

Details

Lambda Jam Practice runs. Please note that it is a week earlier since lambda jam is the next week when we'd normally have our meetup.

Infinite Scroll: Lazy Lists in the Brick TUI Library - Fraser Tweedale
-----------------------------------------------------------------------------------

The Brick terminal UI library provides a rich library of widgets for building console applications in Haskell. These include a list widget, which uses a packed vector type under the hood: a major problem when working with lists that are very large or expensive to compute.

In this case study I will review, step by step, how I generalised Brick's list widget to admit different underlying container types and achieved lazy loading of list items. The presentation will address several topics including:

- The advantages of more general (polymorphic) code, including parametricity
- Ensuring adequate test coverage before refactoring or generalising
- Maintaining backwards compatibility
- Assessing and documenting asymptotic performance
- Using Brick list widget in a real-world application (purebred MUA) for lazy loading where I/O is involved
- How to evaluate a lazy structure in the background (and why you might want to)
- Can we really achieve infinite scroll, or is my presentation title just clickbait?

There will code examples and live demos to justify the work that was done, and show the pleasing results. The presentation uses Haskell exclusively but principles and advice for generalising code apply to many languages.