Skip to content
0:00 / 0:00

#immutability#refactoring#kevlinhenney

Refactoring to Immutability - Kevlin Henney

NDC Conferences

230K subscribers • 110 videos on Hallway • Conference channel

YouTube
  • Recommended by 2 people: 2 in engineering communities.
  • Presented by Kevlin Henney, independent consultant
  • An opinion. It argues one side of a question engineers disagree on.

Intermediate. Assumes working knowledge.

96K views8 years ago2 recommendations

Software designTools and practiceRefactoring and legacy codeFunctional programmingDesign patterns

Kevlin Henney explores practical approaches to reducing state mutability in existing codebases and refactoring toward functional design.

It has been said that immutability changes everything. But what does that mean in practice? What does it mean for existing code that looks more like the mutant apocalypse than an elegant application of mathematical thinking? Immutability can be an ideal that is hard to reach. Refactoring, on the other hand, is all about the art of the possible. In this talk we'll be clarifying motivation and exploring some approaches to help reducing state mutability in code. NDC Conferences ndc-london.com ndcconferences.com

Why it's here

2 people recommend this

What people say. Recommended as an excellent guide to understanding immutability and learning how to transition from imperative to functional thinking.

u/ExtraFig6in r/Clojure • Recommends

On “Thinking in Clojure: shortest path for a long-time imperative programmer?”

If you have a problem in mind, I can try to talk through my thought process for solving it. I will try to show some patterns for converting imperative to functional. I think practicing writing small building blocks in clojure will help a lot, especially if you compare them to the corresponding version in an imperative language. If you have an imperative solution already, it can help to practice converting it to a functional solution. The video Refactoring to Immutability by Kevlin Henney goes over these kinds of transformations. The presentation uses C++, but most of the ideas are general. I can show some small examples of how this refactoring would go. Often, the functional solution…

u/Rogntudjuuuuin r/functionalprogramming • Recommends

On “Can this method be more functional?”

Have a look at Kevlin Henney's talk about refactoring to immutability. Immutability is at the core of FP, although not a necessity. It will force you to think in FP. Try to make a for-loop with immutable variables, then you'll understand. link to this video