SPORTS AND ATHLETICS
Context bound vs Implicit evidence: Performance
In a recent pull request review at work I suggested using context bound to declare effect capabilities instead of implicit values as this is what I see the most in OSS projects and it has also been my preference for a while. It makes the code look nicer even though the latter approach is equivalent. Context bound constraints get translated into implicits values at compile time. #### Context bound
scala def p1[F[_]: Applicative: Console]: F[Unit] = Console[F].putStrLn("a") *> Console[F].putStrLn("b") *> Console[F].putStrLn("c") #### Implicit values scala def p2[F[_]](implicit ev: Applicative[F], c: Console[F]): F[Unit] = c.putStrLn("a") *> c.putStrLn("b") *> c.putStrLn("c") Every time we call Console[F] what we are doing is invoking the “summoner” method normally defined as follows:CHRIS BIRCHALLERIK OSHEIM
ECONOMICS AND ECONOMIC POLICY
Lessons learned while writing a Haskell application
Having introduced Haskell at my last job I wanted to put into practice all the stuff I learned: take the good, leave the bad. So I started working on an exchange rates API using a few libraries I haven’t used before, exclusively for fun and learning purposes. In this blog post I’ll try to share what I have identified as good practice so far and what are my personal recommendations when writing a Haskell application.
MATHEMATICS AND STATISTICS
Functional Dependencies & Type Families
In the past few months I have learnt a lot! Probably the coolest stuff has been about Functional Dependencies and Type Families, so this is my attempt to explain it in order to gain a better understanding and hopefully help someone else out there as well. So please be kind if you see any mistake, let me know and I’ll try to fix it 🙂 ### A motivating example One of the fun applications I’ve worked on is exchange-rates, which uses the RIO Monad (basically
ReaderT + IO).SIMON PEYTON JONESDMITRII KOVANIKOV
EMPLOYMENT AND CAREERS
The art of interviewing engineers
These past few weeks I’ve been interviewing with a few companies, as I’m actively on the lookout for a new challenge, and the number of flaws I have encountered in some hiring processes has disturbed me. Interviewing is hard; interviewing Software Engineers is a work of art. Let’s be honest. Software Engineers, especially in the functional programming space, are a scarce resource. So the better the interview process, the bigger the chances you have of hiring great engineers.
ENERGY AND POWER
Setting up Ghcide in Ubuntu with Nixpkgs
If you use Ubuntu or any other Linux distribution (AKA distro) together with Nixpkgs, you might have noticed things don’t play so well together. Nixpkgs has been mainly designed to work seamlessly in Nix OS; other distros are second class citizens. Quoting the Ghcide repository, it is defined as: #### Quote "A library for building Haskell IDE tooling" It is not defined as an IDE, because it only has a subset of the features HIE (Haskell IDE Engine) has. However, the good news is that the HIE and Ghcide teams are joining forces to create One Haskell IDE to rule them all!