Статья М. П. Джонса, опубликованная в Haskell Workshop Version: September 1, 1999. Посвящена описанию системы типизации языка Haskell, причём реализация машины вывода типов приведена опять же на языке Haskell.<div class="bb-sep"></div>Краткое содержание:<div class="bb-sep"></div>Introduction<br/>Pre
Production Haskell. Succeeding in Industry with Haskell
✍ Scribed by Matt Parsons
- Publisher
- leanpub.com
- Year
- 2023
- Tongue
- English
- Leaves
- 466
- Category
- Library
No coin nor oath required. For personal study only.
✦ Table of Contents
Table of Contents
Introduction
An Opinionated Tour Guide
About the Author
Acknowledgements
Principles
Complexity
Novelty
Cohesion
Empathy
References
I Building Haskell Teams
Selling Haskell
Assessing Receptiveness
Software Productivity
Statistics of Productivity
Know Your Competition
Learning and Teaching Haskell
The Philology of Haskell
Programming Is Hard To Learn
Pick Learning Materials
Write Lots of Code
Don't Fear the GHC
Start Simple
Solve Real Problems
Pair Programming
A Dialogue
References
Hiring Haskellers
The Double-edged Sword
Juniors and Seniors
Hiring Seniors
Hiring Juniors
Evaluating Consultancies
Identifying the Target
Well-Typed
FP Complete
II Application Structure
The Beginning
Abstraction for Mocking
Forward Compatibility
AppEnvironment
The ReaderT Pattern
Embed, don't Stack
Three Layer Haskell Cake
Layer 1: Imperative Programming
Layer 2: Object Oriented Programming
Layer 3: Functional Programming
Examples
Invert Your Mocks!
Decomposing Effects
Streaming Decomposition
Plain ol' abstraction
Decompose!!!
What if I need to?
Project Preludes
Prelude Problems
Custom Benefits
Off-The-Shelf Preludes
Nesting Preludes
Downsides
Using a Custom Prelude
Optimizing GHC Compile Times
The Project.Types Megamodule
Package Splitting
Big Ol' Instances Module
TemplateHaskell
Some random parting thoughts
III Domain Modeling
Type Safety Back and Forth
The Ripple Effect
Ask Only What You Need
Keep Your Types Small…
Expansion and Restriction
Constraints Liberate
Restrict the Range
A perfect fit
The Trouble with Typed Errors
Monolithic error types are bad
Boilerplate be gone!
Type Classes To The Rescue!
The virtue of untyped errors
Exceptions
Exceptions In Five Minutes
Best Practices
Hierarchies
Reinventing
Asynchronous Exceptions
The Theory
HasCallStack
EDSL Design
Tricks with do
Overloaded Literals
Type Inference Trick
Fluent Interfaces
Case Study: Weightlifting Logging
Case Study: rowdy
Case Study: hspec
Growing Pains
A Taxonomy of Breaking Changes
Avoiding Breaking Changes
Communicating To Users
IV Interfacing the Real
Testing
Libraries and Tools
Designing Code for Testing
Logging and Observability
On Debug.Trace
Prefer do Notation
Logging Contexts
Libraries in Brief
Databases
Separate Database Types
Migrations
Access Patterns
Conclusion
V Advanced Haskell
Template Haskell Is Not Scary
A Beginner Tutorial
wait this isn't haskell what am i doing here
Constructing an AST
Boilerplate Be Gone!
Basic Type Level Programming
The Basic Types
The Higher Kinds
Dynamically Kinded Programming
Data Kinds
GADTs
Vectors
Type Families
This Sucks
Heterogeneous Lists
Inductive Type Class Instances
Extensible Records
Like what you read?
Family Values
Type Families
Open or Closed Type Families?
The Bridge Between Worlds
Data Families
Conclusion
Trade-offs in Type Programming
MPTCs
MPTCs + Fundeps
Associated Types
Comparisons
Case Study: Prairie
Problem Statement:
Prior Art
The GADT Approach
Improvements?
Symbols
Compare and Constrast
Identify the Issue
Generalize a GADT
Fundeps
More Class Please
Refining the Class
Template Haskell
Conclusion
📜 SIMILAR VOLUMES
If you are a programmer looking to gain knowledge of Haskell who’s never been properly introduced to functional programming, this book is for you. Basic experience with programming in a non-functional language is a prerequisite. With software systems reaching new levels of complexity and programmer
284 pages ; 21 cm
The original book has a long list of errata (https://manning-content.s3.amazonaws.com/download/4/699ce32-de8b-4b62-880a-9cbd4a0a4624/Kurt_GetProgrammingwithHaskell_err3.html), and even the errata has typo. This file has all of them fixed.
Unlike any other programming language, Haskell is purely functional with a strong type system and lazy evaluation. It is arguable the most interesting language but also has the reputation of being one of the most challenging to learn. Learning Haskell doesn't have to be difficult, and this book can