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
Ruby 2.0
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Jun Lin
November 27, 2012
Programming
170
1
Share
Ruby 2.0
A glance of Ruby 2.0
Jun Lin
November 27, 2012
More Decks by Jun Lin
See All by Jun Lin
A brief introduction to GenStage
linjunpop
1
53
Microservices
linjunpop
0
82
Actor Model
linjunpop
0
35
Ruby for iOS developer
linjunpop
0
1k
A brief introduction to GitHub
linjunpop
1
67
Test Driven Development
linjunpop
0
49
Other Decks in Programming
See All in Programming
Coding at the Speed of Thought: The New Era of Symfony Docker
dunglas
0
4.7k
飯MCP
yusukebe
0
490
Reactive ❤️ Loom: A Forbidden Love Story
franz1981
2
230
Redox OS でのネームスペース管理と chroot の実現
isanethen
0
550
今からFlash開発できるわけないじゃん、ムリムリ! (※ムリじゃなかった!?)
arkw
0
190
2026-03-27 #terminalnight 変数展開とコマンド展開でターミナル作業をスマートにする方法
masasuzu
0
310
의존성 주입과 모듈화
fornewid
0
110
Running Swift without an OS
kishikawakatsumi
0
660
PHP 7.4でもOpenTelemetryゼロコード計装がしたい! / PHPerKaigi 2026
arthur1
1
540
10年分の技術的負債、完済へ ― Claude Code主導のAI駆動開発でスポーツブルを丸ごとリプレイスした話
takuya_houshima
0
1.8k
PHPで TLSのプロトコルを実装してみる
higaki_program
0
740
脱 雰囲気実装!AgentCoreを良い感じにWEBアプリケーションに組み込むために
takuyay0ne
3
440
Featured
See All Featured
GitHub's CSS Performance
jonrohan
1032
470k
Believing is Seeing
oripsolob
1
110
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
96
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7.3k
Become a Pro
speakerdeck
PRO
31
5.9k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9k
Docker and Python
trallard
47
3.8k
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
2.7k
HDC tutorial
michielstock
1
610
Optimizing for Happiness
mojombo
378
71k
Skip the Path - Find Your Career Trail
mkilby
1
100
Transcript
Ruby 2.0
February 24th 2013
Ruby’s 20th birthday.
Faster
Reliable
More fun to use
REFINEMENTS
• A mechanism to extend Classes and Modules locally •
Lexically scoped • Safer and cleaner than open-class monkey patching
• Module#refine • Kernel#using
module Foo refine String do def say "Yoho, #{self}!" end
end end class Bar using Foo def aloha 'Bar'.say end end
Bar.new.aloha => “Yoho, Bar!”
PREPEND
Module#prepend
class A def foo 'foo' end end module B def
foo super + 'bar' end end class C < A prepend B def foo super + 'COOL' end end
C.new.foo => “fooCOOLbar”
LAZY
Enumerator#lazy
(1..Float::INFINITY).lazy.select(&:even?).take(20).force
[2, 4, 6, 8, 10, 12, 14, 16, 18, 20,
22, 24, 26, 28, 30, 32, 34, 36, 38, 40]
KEYWORD ARGUMENT
class Bar def foo(a: "foo", b: 424242) [a, b] end
end
Bar.new.foo => ['foo', 424242]
2.0.0-preview1
END