RSSAmplifier

Blog

Deque

Functions In - Fictions Out

deque.blogRSS feed ↗10 posts

Latest posts

Trip Report on CPPP 19, the first edition of the first C++ french conference

Last Saturday marked the first occurrence of the CPPP, the first ever conference dedicated to C++ on the French soil, organized by Frédéric Tingaud and Joel Falcou. It was one of the lucky to be there for this very first edition, and it was quite an special moment to experience the birth of what promises... Continue Reading

Pythagorean Triples in Modern C++

The post of Eric Niebler on standard ranges and the answer post of Aras (Modern C++ lamentations) generated quite a lot of heat in the C++ community lately. The discussion it triggered was quite interesting, with amazing answers such as the one of Ben Deane, but no answer was as intriguing to me as the... Continue Reading

Distributed Agreement on Random Order – Fun with Lamport Timestamps

If we succeed in this task, we will have succeeded in building what easily qualifies as one of the world most wasteful way to random shuffle. We now have a stupid task to do, and a perfect architecture to do it. We just miss the perfect language for the task It is quite astonishing... Continue Reading

How small programming faults led to overflowing an entire system

It is 10 in the morning. Approaching at 2 o clock, a feature demo. We are supposed to show some of last developments on one of the newest micro-service of the platform. The code worked nice before. We did not touch the implementation of the service since the last tests. There is no reason why it... Continue Reading

How to use tag dispatching in your code more effectively?

This post is an answer to the C++ blog post How to Use Tag Dispatching In Your Code Effectively. I read the article, its main example and the guideline it delivers, and I am not convinced it really works. This blog post aims at expressing my thoughts, offer an alternative simpler way to solve the... Continue Reading

Continuation passing style Free Monads and direct style Free Monads

Generalized Algebraic Data Types gives us the power to develop type-safe Free Monads, without having to rely on continuation passing style when using simple Algebraic Data Types. The resulting Abstract Syntax Tree acts as easy to understand specifications for the interpreters of the language it defines. In today s post, we will revisit the first... Continue Reading

Answering r/haskell: How to unit test code that uses polymorphic interfaces?

This short post is an answer to the following question asked on r/haskell. The original question is about how to test code that lives in a Monad class with polymorphic functions. I highly encourage you to read the post. Its different answers are full of technical gems which we are not going to explore here... Continue Reading

C++ Design Tip: Objects should not point back to an object that owns them

In today s post, we will be advising against storing back-pointers in objects. This is something that we can find in our code, and which unfortunately leads to bugs, decreased performance, code that is harder to reason about and cannot be used in generic algorithms such as the STL ones. We will first describe these numerous... Continue Reading

Free Monads: from the basics to the implementation of composable and effectful stream processing

In the previous post, we introduced IdrisPipes, a library for composable and effectful production, transformation and consumption of streams of data in Idris. We talked about the motivations behind this library, its API and its model, and some of the features it offers. In this post, we will embark in a journey from the basics... Continue Reading

IdrisPipes: a library for composable and effectful stream processing in Idris

We will continue our series on post on Idris, by implementing a pipe library for Idris, inspired by the great Haskell pipes and Haskell conduit libraries. The goal is to provide Idris with a library for composable and effectful production, transformation and consumption of streams of data. In short, IdrisPipes is an Idris package that... Continue Reading