Settings

Theme

Reflections on Haskell and Rust

academy.fpblock.com

3 points by runeks 5 months ago · 2 comments

Reader

runeksOP 5 months ago

Regarding the shadowing example, you probably wouldn't write

  config <- loadConfig
  config' <- validateConfig config
  config'' <- mergeDefaults config'
in Haskell but rather

  config <- mergeDefaults =<< validateConfig =<< loadConfig
  • kreyenborgi 5 months ago

    I would just shadow (it works)

      config <- loadConfig
      config <- validateConfig config
      config <- mergeDefaults config

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection