Myvideo

Guest

Login

GHC Language Extensions Andrew McMiddlin YOW! 2019

Uploaded By: Myvideo
1 view
0
0 votes
0

This presentation was recorded at YOW! 2019. #GOTOcon #YOW Andrew McMiddlin - Functional Programming Engineer in the Queensland Functional Programming Lab at Data61 RESOURCES ABSTRACT #LanguageExtensions are everywhere in the modern #Haskell world. As beginners we are often told by instructors or the compiler itself to enable particular extensions to allow for some syntactic sugar or enable a common feature. If we continue to use Haskell, we likely come to depend on even more language extensions, until it is common place for the first 10 lines of each file to be #LanguagePragmas. Many of us, myself included, are probably guilty of enabling extensions without fully understanding what they do, or understanding what tradeoffs and risks they might present. This talk hopes to improve the situation by shedding some light on commonly used extensions. We'll start with what language extensions are and why they exist. Next we'll consider the different ways they may be enabled. From there, we'll look at some of the simpler extensions that provide syntactic sugar and not much else --- for example, LambdaCase and TupleSections. At this point we'll start to ramp up and look at some heavier weight extensions (e.g. ScopedTypeVariables and GeneralizedNewtypeDeriving), their use cases, and their tradeoffs. Finally, we'll take a more detailed look at some language extensions related to type classes. Specifically; FlexibleInstances, FlexibleContexts, MultiParamTypeClasses, and FunctionalDependencies will be covered. There are over 100 language extensions supported by #GHC 8.6, so it is not my intention to cover all or even most of them. Instead, I hope to explain and demystify some common language extensions and point out that they are not without risks. [...] RECOMMENDED BOOKS Vitaly Bragilevsky • Haskell in Depth • Rebecca Skinner • Effective Haskell • Graham Hutton • Programming in Haskell • John Whitington • Haskell from the Very Beginning • #FunctionalPrgramming #FP #AndrewMcMiddlin #SoftwareEngineering #Programming #YOWcon Looking for a unique learning experience? Attend the next GOTO conference near you! Get your ticket at Sign up for updates and specials at SUBSCRIBE TO OUR CHANNEL - new videos posted almost daily.

Share with your friends

Link:

Embed:

Video Size:

Custom size:

x

Add to Playlist:

Favorites
My Playlist
Watch Later