Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Staging with Class - A Specification for Typed Template Haskell

GOTO Conferences via YouTube

Overview

This course focuses on teaching multi-stage programming using typed code quotation, specifically addressing the challenges that arise when dealing with type classes in Haskell. The learning outcomes include understanding the interaction between quotation and type classes, resolving this interaction with staged type class constraints, and ensuring type soundness in both source and core programs. Participants will learn about incorporating type classes into multi-stage programs with confidence. The course covers topics such as code generation, well-typedness, well-stagedness, level-indexed constraint resolution, and type-directed elaboration. The teaching method involves presenting recent research work through a formalized source calculus that elaborates into an explicit core calculus. This course is intended for programmers interested in multi-stage programming, code generation, and incorporating type classes into their programs.

Syllabus

Intro
Quotations and splices
Multi-stage programming: example
Code generation
Multi-stage programming and type classes
Multi-stage programming: well-typedness
Well-stagedness: the level of an expression
Well-stagedness: the level restriction
Is the problem with qpower well-stageness?
Well-staged type classes
Key idea: staged type class constraints
Level-indexed constraint resolution
How to evaluate staged programs?
Level-indexed Evaluation
Key idea: splice environments
Type-directed elaboration
Integration into GHC

Taught by

GOTO Conferences

Reviews

Start your review of Staging with Class - A Specification for Typed Template Haskell

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.