Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Lispy Elixir
Search
Patrick Gombert
May 16, 2014
Technology
150
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Lispy Elixir
Patrick Gombert
May 16, 2014
More Decks by Patrick Gombert
See All by Patrick Gombert
Introduction to Erlang (8LU)
patrickgombert
3
170
Other Decks in Technology
See All in Technology
関東Kaggler会発表資料
takoi
1
210
認知負荷をGemini で溶かす — GKE 基盤「Orbit」における AI エージェントの実践
sansantech
PRO
1
280
変化の早いClaude Codeを 書籍に落とし込む
oikon48
7
1.4k
Eight Engineering Unit 紹介資料
sansan33
PRO
3
8.1k
20260804_Q4AzureUpdateBite_FabricDataAgentの精度を高める設計.pdf
matayuuu
1
120
オートロックマンションなのに、各部屋は施錠なし!? 攻撃者が組織内ネットワークで大暴れする理由 / The Front Door Is Locked, but the Rooms Are Wide Open: Why Attackers Move Freely Inside Enterprise Networks
nttcom
1
1.6k
toio・myCobotでフィジカルAIっぽいことを行うための検討(とりあえず調査) / フィジカルAI LT(IoTLTによる開催)
you
PRO
0
310
【CEDEC2026】『GRANBLUE FANTASY: Relink - Endless Ragnarok』のバトル制作事例 ~最高のキャラゲーを目指して~
cygames
PRO
0
230
【CEDEC2026】グラフィックスエンジニアのためのニューラルシェーディング入門
cygames
PRO
0
130
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
4.9k
FPGAが実現する遠方宇宙の高空間分解能天体撮影 -大型地上望遠鏡の視力を補正する「補償光学」とは?-
komei_mt
0
210
Model Studio CLI × Token Plan
maigo999
0
130
Featured
See All Featured
Fashionably flexible responsive web design (full day workshop)
malarkey
408
67k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
49
10k
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7.8k
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.5k
Building an army of robots
kneath
306
46k
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
1
230
The Cost Of JavaScript in 2023
addyosmani
55
10k
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
66
57k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.5k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.8k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
232
55k
Transcript
Lispy Elixir @PatrickGombert
Lisp crash course (LISt Processing) () ; data structure (f)
; data structure and executable code (1 2 3) ; data structure without executable code ! ; closure definition ! ; program returning 4
Composability ; Higher order function ! ; Function returning a
function ! ; equivalent to !
Elixir is composable ; Higher order function ! ; Function
returning a function ! equivalent to
Homoiconicity - Code is represented as data (everything is a
list in lisp) - The resulting structure is a form of Abstract Syntax Tree (+ ; Root Node (+ ; Child of Root 1 ; Leaf Node 2) ; Leaf Node (+ ; Child of Root 3 ; Leaf Node 4)) ; Leaf Node !
Elixir is homocionic… ?
Look past syntax, you must
Quote This doesn’t print hello world, but why?
I heard you like programs in your programs
Elixir allows you to program while you program!
Homoiconic AST function arguments
Not quite as elegant… vs.
ISMETA (http://xkcd.com/917/) = =
! Erlang’s Parse-Transform http://www.erlang.org/doc/apps/erts/absform.html
… or lisp style macros! - Compile time (like parse-transform)
! - Homoiconic AST manipulation (like parse-transform) ! - Consistent AST (!!!)
defmacro ! ! - all at compile time - quoted
arguments - returning ASTs for the evaluation in the current module
None
None
None
List Comprehensions
And without the commas
It’s macros (almost) all the way down Turtle = Macro
Erm… umm…
! So of course…
None
Slow down cowboy It’s a context switch between compile &
run times
Macro bootstrap step https://github.com/elixir-lang/elixir/blob/master/lib/elixir/ src/elixir_bootstrap.erl
Splicing
Hygiene Note: Elixir is immutable so the rebinding is in
the local scope
Thanks! @PatrickGombert