Welcome to another issue of Haskell Weekly! Haskell is a safe, purely functional programming language with a fast, concurrent runtime. This is a weekly summary of what’s going on in its community.
Aggregating data is a common, tedious task. In imperative languages we often end up with a rat’s nest of mutable variables, nested loops and other awful constructs. In functional languages a naive implementation also results in spaghetti and usually less than ideal performance.
Well written code based on unboxed arrays and using the discussed pattern to create arrays by initializing a mutable version, which is subsequently frozen, can achieve performance comparable to low-level C code.
The reason for this tutorial is not that you need to know all of this in order to use apecs. For simple 2D games, apecs won’t be a bottleneck. Once you start worrying about 3D and render times however, that’s when you might need apecs to be fast, and this is how you do that.
How can we know when to be lazy or strict? We can use Dhall’s type system to guide whether or not we keep the accumulator strict. We already have access to the type of the accumulator for our loop, so we can define a function that tells us if our accumulator type is compact or not.
To tame that complexity, we factored the “what to do next” back out into a new data type, this time called
Listare similar; and we can use
Listand other interesting data structures.
Of course the title is a click bait and I do not mean to be so categorical. Free monads do have their uses, but in most cases I’d think twice before committing to that style of programming because it’s somewhat tedious and inefficient.
We’ll be building up pieces of a todo-list application along the way. It is probably becoming a cliche by now, but it is familiar to a lot of people and will give me something concrete to use while demonstrating some of the cooler things that
reflexprovides as the series progresses.
The aim of this post is to show another way of achieving the same result, with tools that are available in PureScript — a strongly-typed functional language, with no dependent types.
This article: Introduces the Delta Debugging technique; Implements a general-purpose delta-debugging tool; Uses Haskell’s FFI to control a C chess engine; Locates an error introduced into the chess engine.
Mission: Facilitate a Linux future for VR & AR Desktop. In the short-run, this means allowing people to run 2D Linux apps with current generation headsets. In the long-run, this means allowing people to run Linux in standalone AR & VR HMDs.
We’re Wrinkl, a well-funded startup working closely with Obsidian Systems to build a powerful new communications platform. We use Haskell on both the backend and the frontend (using GHCJS and Reflex). And we’re looking to hire Haskell developers, preferably in the Philly area or willing to relocate to Philly. Women and minorities strongly encouraged to apply.
- Alternatives to typed holes for talking to your compiler
- Automating the build of your technical presentation
- Formlets are biapplicative
- Grenade! Dependently typed neural networks
- Rust has safety features, yet when we talk about safety in Haskell we’re not talking about the same kind of safety
- What library do I use to do X?
- Why lenses work
- Wire server code now 100% open source: The journey continues
Package of the week
This week’s package of the week is tree-diff,
a library for diffing expression trees.
It also provides a way to diff arbitrary data types using
Call for participation
Unfortunately we don’t know of any Haskell events. Do you know of an event that Haskell users would enjoy? Let us know about it by emailing [email protected]!