iron* - an introduction to getting dynamic on .net
DESCRIPTION
In recent years dynamically typed languages have received more and more attention on the .NET platform. Initially, an implementation of Python showed up. Later, the Dynamic Language Runtime (DLR) appeared which made it much easier to implement dynamically typed languages on .NET. This session explores how dynamically typed languages fit in the ecosystem of .NET. We’ll see why dynamic languages are interesting and contrast them to their static brethren (C#, Java). Then we will touch on how IronPython and IronRuby are implemented on .NET via the Dynamic Language Runtime (DLR). Finally, we’ll look at some code examples of how you can utilize these languages on .NET today.TRANSCRIPT
![Page 1: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/1.jpg)
Iron* - An Introduction to Getting Dynamic on
.NET //kristiankristensen.dk
twitter.com/kkristensen
![Page 2: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/2.jpg)
Question
![Page 3: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/3.jpg)
Dynamic Languages
Dynamic Language Runtime
Demo!
45 min 15 min
Agenda
![Page 4: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/4.jpg)
Why Dynamic Languages
Fashion
Fame
Weight Loss
Interest
Fortune
![Page 5: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/5.jpg)
What makes a language “dynamic”?
![Page 6: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/6.jpg)
![Page 7: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/7.jpg)
http://www.flickr.com/photos/35064820@N00/3950391591/
![Page 8: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/8.jpg)
![Page 9: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/9.jpg)
http://www.flickr.com/photos/janineberben/3219556705/
![Page 10: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/10.jpg)
Why Dynamic Languages
Simplicity
Expressive Perspective
![Page 11: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/11.jpg)
![Page 12: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/12.jpg)
![Page 13: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/13.jpg)
The traditional view of the world
Dynamic Languages
Simple and succinct
Implicitly typed
Meta-programming
No compilation
Static Languages
Robust
Performance
Intelligent tools
Better scaling
![Page 14: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/14.jpg)
Dynamic Language Runtime
![Page 15: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/15.jpg)
Dynamic Languages on .NET
IronPython IronRuby
C# VB.NET
Common Language Runtime
Iron?
![Page 16: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/16.jpg)
Multiple Language Dynamic Dispatch
Object Binder
Python Binder
Ruby Binder
COM Binder
Dynamic Language Runtime
GetMember Name=“Foo”, IgnoreCase=false
IronPython x.Foo
IronRuby x.Foo
C# x.Foo
VB.NET x.Foo
![Page 17: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/17.jpg)
Common Language = CLR + DLR
Today’s view of the world
Dynamic Languages
Simple and succinct
Implicitly typed
Meta-programming
No compilation
Static Languages
Robust
Performance
Intelligent tools
Better scaling
![Page 18: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/18.jpg)
![Page 19: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/19.jpg)
Iron languages are first class .NET citizens
![Page 20: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/20.jpg)
IronWhat? • True language implementation
– True to the language
– True to the community
– True to the experience
– Excellent performance
• Great integration with .NET – Easy to use .NET libraries
– Easy to use other .NET languages
– Easy to use in .NET hosts
– Easy to use with .NET tools
• Implementation Running On .NET
![Page 21: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/21.jpg)
![Page 22: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/22.jpg)
Languages on DLR
• Pictures
![Page 23: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/23.jpg)
Why Iron* Languages?
Easy to extend
Easy to embed
.NET Interop
![Page 24: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/24.jpg)
” Talk is cheap. Show me the code.” - Linus Torvalds
http://en.wikiquote.org/wiki/Linus_Torvalds
![Page 25: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/25.jpg)
Ruby Test Framework
![Page 26: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/26.jpg)
[TestClass] public class StackTest { [TestMethod] public void NewStackHasZeroElements() { var s = new Stack<string>(); Assert.AreEqual<int>(0, s.Count); } [TestMethod] public void StackPeekTopElement() { var s = new Stack<string>(); s.Push("bob"); Assert.AreEqual<int>(1, s.Count); Assert.AreEqual<string>("bob", s.Peek()); } [TestMethod] public void StackPopTopElement() { var s = new Stack<string>(); s.Push("bob"); Assert.AreEqual<string>("bob", s.Pop()); Assert.AreEqual<int>(0, s.Count); } }
![Page 27: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/27.jpg)
IronPython in Visual Studio
http://ironpython.net/tools
![Page 28: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/28.jpg)
Easy to embed aka BadPaint
![Page 29: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/29.jpg)
The road ahead (picture)
![Page 30: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/30.jpg)
![Page 31: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/31.jpg)
http://ironpython.net
http://ironruby.net
http://dlr.codeplex.com
![Page 32: Iron* - An Introduction to Getting Dynamic on .NET](https://reader033.vdocuments.site/reader033/viewer/2022052823/5552dd98b4c90532498b4cd2/html5/thumbnails/32.jpg)
The end.