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
Elixir
Search
Plataformatec
November 18, 2012
Technology
17
11k
Elixir
This talk highlights the reason, goals and roadmap behind Elixir,
http://elixir-lang.org
Plataformatec
November 18, 2012
Tweet
Share
More Decks by Plataformatec
See All by Plataformatec
O case da Plataformatec com o Elixir - Como uma empresa brasileira criou uma linguagem que é usada no mundo inteiro @ Elixir Brasil 2019
plataformatec
5
960
O case da Plataformatec com o Elixir - Como uma empresa brasileira criou uma linguagem que é usada no mundo inteiro @ QCon SP 2018
plataformatec
1
220
Elixir @ iMasters Intercon 2016
plataformatec
1
260
GenStage and Flow by @josevalim at ElixirConf
plataformatec
17
2.7k
Elixir: Programação Funcional e Pragmática @ 2º Tech Day Curitiba
plataformatec
2
290
Elixir: Programação Funcional e Pragmática @ Encontro Locaweb 2016
plataformatec
4
280
What's ahead for Elixir: v1.2 and GenRouter
plataformatec
15
2k
Arquiteturas Comuns de Apps Rails @ RubyConf BR 2015
plataformatec
6
370
Pirâmide de testes, escrevendo testes com qualidade @ RubyConf 2015
plataformatec
10
2.3k
Other Decks in Technology
See All in Technology
JuliaTokaiとJuliaLangJaの紹介 for NGK2025S
antimon2
1
110
AWSマルチアカウント統制環境のすゝめ / 20250115 Mitsutoshi Matsuo
shift_evolve
0
100
My small contributions - Fujiwara Tech Conference 2025
ijin
0
1.4k
Reactフレームワークプロダクトを モバイルアプリにして、もっと便利に。 ユーザに価値を届けよう。/React Framework with Capacitor
rdlabo
0
110
2024年活動報告会(人材育成推進WG・ビジネスサブWG) / 20250114-OIDF-J-EduWG-BizSWG
oidfj
0
120
ドメイン駆動設計の実践により事業の成長スピードと保守性を両立するショッピングクーポン
lycorptech_jp
PRO
9
840
2025年のARグラスの潮流
kotauchisunsun
0
790
Formal Development of Operating Systems in Rust
riru
1
420
東京Ruby会議12 Ruby と Rust と私 / Tokyo RubyKaigi 12 Ruby, Rust and me
eagletmt
3
850
CDKのコードレビューを楽にするパッケージcdk-mentorを作ってみた/cdk-mentor
tomoki10
0
200
[IBM TechXchange Dojo]Watson Discoveryとwatsonx.aiでRAGを実現!事例のご紹介+座学②
siyuanzh09
0
110
カップ麺の待ち時間(3分)でわかるPartyRockアップデート
ryutakondo
0
130
Featured
See All Featured
How to Ace a Technical Interview
jacobian
276
23k
Designing for humans not robots
tammielis
250
25k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
29
960
VelocityConf: Rendering Performance Case Studies
addyosmani
327
24k
Facilitating Awesome Meetings
lara
51
6.2k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
3
240
Building Your Own Lightsaber
phodgson
104
6.2k
Agile that works and the tools we love
rasmusluckow
328
21k
Bootstrapping a Software Product
garrettdimon
PRO
305
110k
Rebuilding a faster, lazier Slack
samanthasiow
79
8.8k
Building an army of robots
kneath
302
45k
The World Runs on Bad Software
bkeepers
PRO
66
11k
Transcript
@elixirlang / elixir-lang.org Monday, November 19, 2012
@josevalim Monday, November 19, 2012
Monday, November 19, 2012
Why? Monday, November 19, 2012
case #1 Monday, November 19, 2012
Switch Switch Monday, November 19, 2012
Switch Browser Endpoint Server Monday, November 19, 2012
Server Browser Monday, November 19, 2012
•Web sockets •API streaming •Server sent events Server Monday, November
19, 2012
case #2 Multi-core Monday, November 19, 2012
Server Server Server Server Monday, November 19, 2012
50 cores $2600 Monday, November 19, 2012
Server Monday, November 19, 2012
case #3 Doing it live! Monday, November 19, 2012
http://blog.whatsapp.com/index.php/2012/01/1-million-is-so-2011/ 2 million connections on a single node Monday, November
19, 2012
http://stackoverflow.com/questions/1636455/where-is-erlang-used-and-why Monday, November 19, 2012
Goals Monday, November 19, 2012
goal #1 Productivity Monday, November 19, 2012
Everything is an expression Monday, November 19, 2012
-module(my_module). some_function(Foo) -> % ... other_function(Bar) -> % ... erlang
Monday, November 19, 2012
-module(my_module). % won’t compile io:put_chars("hello"). some_function(Foo) -> % ... other_function(Bar)
-> % ... erlang Monday, November 19, 2012
defmodule MyModule do def some_function(foo) do # ... end IO.puts
"hello" def other_function(bar) do # ... end end elixir Monday, November 19, 2012
Macros Monday, November 19, 2012
:foo - atoms/symbols { 1, 2, 3 } - tuples
[ 1, 2, 3 ] - lists Monday, November 19, 2012
is_atom(:foo) function line args atom { :is_atom, 1, [:foo] }
Monday, November 19, 2012
1 + 2 function line args { :+, 1, [1,2]
} Monday, November 19, 2012
defmacro unless(expr, opts) do quote do if(!unquote(expr), unquote(opts)) end end
unless(true, do: exit()) elixir Monday, November 19, 2012
Domain Specific Languages Monday, November 19, 2012
defmodule MathTest do use ExUnit.Case test "basic operations" do assert
1 + 1 == 2 end end elixir Monday, November 19, 2012
defmodule MathTest do use ExUnit.Case def test_basic_operations do assert 1
+ 1 == 2 :ok end end elixir Monday, November 19, 2012
assert 1 + 1 == 2 { :==, 5, [1
+ 1, 2] } function line args Monday, November 19, 2012
# assert 1 + 1 == 2 defmacro assert({ :=~,
line, [l,r] }) do # ... end defmacro assert({ :==, line, [l,r] }) do # ... end defmacro assert(default) do # ... end Monday, November 19, 2012
goal #2 Extensibility Monday, November 19, 2012
-module(json). to_json(Item) when is_list(Item) -> % ... to_json(Item) when is_binary(Item)
-> % ... to_json(Item) when is_number(Item) -> % ... erlang Monday, November 19, 2012
Protocols Monday, November 19, 2012
defprotocol JSON do def to_json(item) end JSON.to_json(item) elixir Monday, November
19, 2012
defimpl JSON, for: List do # ... end elixir defimpl
JSON, for: Binary do # ... end defimpl JSON, for: Number do # ... end Monday, November 19, 2012
defimpl JSON, for: Array do # ... end elixir Monday,
November 19, 2012
goal #3 Compatibility Monday, November 19, 2012
Monday, November 19, 2012
DISTRIBUTED FAULT-TOLERANT APPLICATIONS WITH HOT-CODE SWAPPING Monday, November 19, 2012
There is no conversion cost for calling Erlang from Elixir
and vice-versa Monday, November 19, 2012
• UTF-8 binaries strings • Keyword arguments • First-class documentation
• First-class regular expressions • Zero-index access • ... Monday, November 19, 2012
Example Monday, November 19, 2012
defmodule MathTest do use ExUnit.Case, async: true test "basic operations"
do assert 1 + 1 == 2 end end elixir Monday, November 19, 2012
1 MathTest 2 SystemTest 3 ... 4 ... 5 ...
6 ... 7 ... 8 ... ExUnit. Runner ExUnit. Formatter Monday, November 19, 2012
1 MathTest 2 SystemTest 3 ... 4 ... 5 ...
6 ... 7 ... 8 ... ExUnit. Runner run ExUnit. Formatter Monday, November 19, 2012
1 MathTest 2 SystemTest 3 ... 4 ... 5 ...
6 ... 7 ... 8 ... ExUnit. Runner run ExUnit. Formatter Monday, November 19, 2012
1 MathTest 2 SystemTest 3 ... 4 ... 5 ...
6 ... 7 ... 8 ... ExUnit. Runner run ExUnit. Formatter Monday, November 19, 2012
1 MathTest 2 SystemTest 3 ... 4 ... 5 ...
6 ... 7 ... 8 ... ExUnit. Runner done ExUnit. Formatter info Monday, November 19, 2012
1 MathTest 2 SystemTest 3 ... 4 ... 5 ...
6 ... 7 ... 8 ... ExUnit. Runner ExUnit. Formatter run Monday, November 19, 2012
127.0.0.9 127.0.0.3 1 MathTest 2 SystemTest 3 ... 4 ...
5 ... 6 ... 7 ... 8 ... ExUnit. Runner ExUnit. Formatter Monday, November 19, 2012
127.0.0.9 127.0.0.3 1 MathTest 2 SystemTest 3 ... 4 ...
5 ... 6 ... 7 ... 8 ... ExUnit. Runner ExUnit. Formatter ExUnit. Supervisor Monday, November 19, 2012
Roadmap Monday, November 19, 2012
• v0.6 (Aug/12) Erlang language compatibility • v0.8 (Dec/12) Erlang
apps support • Dynamo (xx/13) Web framework • v0 (Jan/11) Monday, November 19, 2012
Monday, November 19, 2012
@elixirlang / elixir-lang.org Monday, November 19, 2012