SlideShare a Scribd company logo
1 of 29
rodolfof@lagash.com 
http://shockbyte.net
Fundamentos de un compilador
class Program 
{ 
void Main() 
{ 
} 
} ▫ 
program.exe 
CSC - VBC
5
6
http://irony.codeplex.com
Roslyn
Windows Convergence 
Universal projects 
Cloud Services 
.NET support for 
Azure Mobile Services 
Web apps Native compilation 
ASP.NET updates .NET Native 
Core .NET 
Runtime Compilers 
Next gen JIT (“RyuJIT”) 
SIMD 
.NET Compiler Platform (“Roslyn”) 
Languages innovation 
Azure and Windows Server Windows Desktop 
Openness 
Windows Store iOS and Android 
.NET in devices and services
Editor Services Code Actions Classification Completion Outlining … 
Code Formatting Find All References Name Simplification … 
Symbol 
API 
Services 
Compiler 
Syntax Tree 
API 
Binding and Flow 
Analysis APIs 
Emit API 
Scripting 
API 
Workspace API
Syntax Tree API – Nodes 
CompilationUnit 
TypeDeclaration 
MethodDeclaration 
class C 
{ 
void M() 
{ 
} 
}// C 
▫ 
ParameterList Block 
var tree = CSharpSyntaxTree.ParseText("...");
Syntax Tree API – Tokens 
CompilationUnit 
TypeDeclaration 
EOF 
class C { MethodDeclaration } 
void M ParameterList Block 
( ) { } 
class C 
{ 
void M() 
{ 
} 
}// C 
▫
Syntax Tree API – Trivia 
CompilationUnit 
TypeDeclaration 
EOF 
class C { MethodDeclaration } 
SP EOL EOL // C 
void M ParameterList Block 
( ) 
{ } 
SPx4 SP 
EOL 
EOL 
SPx4 EOL SPx4 EOL 
class∙C 
{ 
∙∙∙∙void∙M() 
∙∙∙∙{ 
∙∙∙∙} 
}// C 
▫
Workspace API 
Host Environment 
Events (e.g. key presses) 
Workspace 
Solution 
Edit Edit 
Project Project 
Compilation 
Document Document 
Apply 
Solution2 Solutionn 
SyntaxTree
C# 6
public class Point(int x, int y) 
{ 
public int X { get; } = x; 
public int Y { get; } = y; 
public double R { get; } = Math.Sqrt(x ^ x + y ^ y); 
public Point() : this(0, 0) 
{ } 
public override string ToString() 
{ 
return string.Format("({0},{1},{2})", X, Y, R); 
} 
}
try 
{ 
Task[] tasks = new Task[10]; 
for (int i = 0; i < 10; i++) 
{ 
tasks[i] = Task.Factory.StartNew(() => DoSomeWork(10000000)); 
} 
var res = await Task.WhenAll(tasks); 
} 
catch (AggregateException e) if (e.InnerExceptions.Count > 2) 
{ 
await WriteStatus(“filtered exception"); 
} 
finally 
{ 
await WriteStatus(“finished"); 
}
http://goo.gl/4vtQfr
¿Preguntas?
http://irony.codeplex.com 
http://roslyn.codeplex.com
¡ Gracias! 
rodolfof@lagash.com 
http://shockbyte.net

More Related Content

What's hot

Vancouver Erlang Meetup cferl & Mule Transport Plug
Vancouver Erlang Meetup cferl & Mule Transport PlugVancouver Erlang Meetup cferl & Mule Transport Plug
Vancouver Erlang Meetup cferl & Mule Transport Plug
David Dossot
 

What's hot (18)

GOCON Autumn (Story of our own Monitoring Agent in golang)
GOCON Autumn (Story of our own Monitoring Agent in golang)GOCON Autumn (Story of our own Monitoring Agent in golang)
GOCON Autumn (Story of our own Monitoring Agent in golang)
 
.Net passé, présent et futur
.Net passé, présent et futur.Net passé, présent et futur
.Net passé, présent et futur
 
“ASP.NET Core. Features and architecture”
“ASP.NET Core. Features and architecture” “ASP.NET Core. Features and architecture”
“ASP.NET Core. Features and architecture”
 
Flink Forward Berlin 2017: Dominik Bruhn - Deploying Flink Jobs as Docker Con...
Flink Forward Berlin 2017: Dominik Bruhn - Deploying Flink Jobs as Docker Con...Flink Forward Berlin 2017: Dominik Bruhn - Deploying Flink Jobs as Docker Con...
Flink Forward Berlin 2017: Dominik Bruhn - Deploying Flink Jobs as Docker Con...
 
Engineering Efficiency in LINE
Engineering Efficiency in LINEEngineering Efficiency in LINE
Engineering Efficiency in LINE
 
Akmal Khaleeq Waheed - Challenge 3 p2
Akmal Khaleeq Waheed - Challenge 3 p2Akmal Khaleeq Waheed - Challenge 3 p2
Akmal Khaleeq Waheed - Challenge 3 p2
 
Android: a full-stack to consume a REST API
Android: a full-stack to consume a REST APIAndroid: a full-stack to consume a REST API
Android: a full-stack to consume a REST API
 
Fast and Reliable Swift APIs with gRPC
Fast and Reliable Swift APIs with gRPCFast and Reliable Swift APIs with gRPC
Fast and Reliable Swift APIs with gRPC
 
Code quality par Simone Civetta
Code quality par Simone CivettaCode quality par Simone Civetta
Code quality par Simone Civetta
 
Android kotlin coroutines
Android kotlin coroutinesAndroid kotlin coroutines
Android kotlin coroutines
 
Nodejs intro
Nodejs introNodejs intro
Nodejs intro
 
OHHttpStubs
OHHttpStubsOHHttpStubs
OHHttpStubs
 
Vancouver Erlang Meetup cferl & Mule Transport Plug
Vancouver Erlang Meetup cferl & Mule Transport PlugVancouver Erlang Meetup cferl & Mule Transport Plug
Vancouver Erlang Meetup cferl & Mule Transport Plug
 
DanNotes 2013: OpenNTF Domino API
DanNotes 2013: OpenNTF Domino APIDanNotes 2013: OpenNTF Domino API
DanNotes 2013: OpenNTF Domino API
 
What's New in ASP.NET Core 2.0
What's New in ASP.NET Core 2.0What's New in ASP.NET Core 2.0
What's New in ASP.NET Core 2.0
 
202107 - Orion introduction - COSCUP
202107 - Orion introduction - COSCUP202107 - Orion introduction - COSCUP
202107 - Orion introduction - COSCUP
 
Developer-friendly taskqueues: What you should ask yourself before choosing one
Developer-friendly taskqueues: What you should ask yourself before choosing oneDeveloper-friendly taskqueues: What you should ask yourself before choosing one
Developer-friendly taskqueues: What you should ask yourself before choosing one
 
Building RESTful Services With Go and MongoDB
Building RESTful Services With Go and MongoDBBuilding RESTful Services With Go and MongoDB
Building RESTful Services With Go and MongoDB
 

Viewers also liked (9)

Windows 10 Developer Readiness
Windows 10 Developer ReadinessWindows 10 Developer Readiness
Windows 10 Developer Readiness
 
ASP.NET 5
ASP.NET 5ASP.NET 5
ASP.NET 5
 
.NET Multiplataforma
.NET Multiplataforma .NET Multiplataforma
.NET Multiplataforma
 
Aplicaciones Real-Time con SignalR
Aplicaciones Real-Time con SignalRAplicaciones Real-Time con SignalR
Aplicaciones Real-Time con SignalR
 
Azure IoT Hub
Azure IoT HubAzure IoT Hub
Azure IoT Hub
 
ASP.NET Core 1.0
ASP.NET Core 1.0ASP.NET Core 1.0
ASP.NET Core 1.0
 
Introduccion a Node.js
Introduccion a Node.jsIntroduccion a Node.js
Introduccion a Node.js
 
IoT y Dispositivos
IoT y DispositivosIoT y Dispositivos
IoT y Dispositivos
 
Despliegue y Monitoreo de aplicaciones ASP.NET Core en Linux
Despliegue y Monitoreo de aplicaciones ASP.NET Core en LinuxDespliegue y Monitoreo de aplicaciones ASP.NET Core en Linux
Despliegue y Monitoreo de aplicaciones ASP.NET Core en Linux
 

Similar to Roslyn: el futuro de C#

JSLounge - TypeScript 소개
JSLounge - TypeScript 소개JSLounge - TypeScript 소개
JSLounge - TypeScript 소개
Reagan Hwang
 
ADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developersADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developers
Bartosz Kosarzycki
 
Visual Studio .NET2010
Visual Studio .NET2010Visual Studio .NET2010
Visual Studio .NET2010
Satish Verma
 
Visual studio 2008
Visual studio 2008Visual studio 2008
Visual studio 2008
Luis Enrique
 

Similar to Roslyn: el futuro de C# (20)

ASP.NET
ASP.NETASP.NET
ASP.NET
 
Roslyn and C# 6.0 New Features
Roslyn and C# 6.0 New FeaturesRoslyn and C# 6.0 New Features
Roslyn and C# 6.0 New Features
 
.NET Foundation, Future of .NET and C#
.NET Foundation, Future of .NET and C#.NET Foundation, Future of .NET and C#
.NET Foundation, Future of .NET and C#
 
Kotlin Developer Starter in Android projects
Kotlin Developer Starter in Android projectsKotlin Developer Starter in Android projects
Kotlin Developer Starter in Android projects
 
Kotlin Developer Starter in Android - STX Next Lightning Talks - Feb 12, 2016
Kotlin Developer Starter in Android - STX Next Lightning Talks - Feb 12, 2016Kotlin Developer Starter in Android - STX Next Lightning Talks - Feb 12, 2016
Kotlin Developer Starter in Android - STX Next Lightning Talks - Feb 12, 2016
 
JSLounge - TypeScript 소개
JSLounge - TypeScript 소개JSLounge - TypeScript 소개
JSLounge - TypeScript 소개
 
Design Patterns - Compiler Case Study - Hands-on Examples
Design Patterns - Compiler Case Study - Hands-on ExamplesDesign Patterns - Compiler Case Study - Hands-on Examples
Design Patterns - Compiler Case Study - Hands-on Examples
 
TechTalk - Dotnet
TechTalk - DotnetTechTalk - Dotnet
TechTalk - Dotnet
 
JVM Mechanics: When Does the JVM JIT & Deoptimize?
JVM Mechanics: When Does the JVM JIT & Deoptimize?JVM Mechanics: When Does the JVM JIT & Deoptimize?
JVM Mechanics: When Does the JVM JIT & Deoptimize?
 
Дмитрий Верескун «Синтаксический сахар C#»
Дмитрий Верескун «Синтаксический сахар C#»Дмитрий Верескун «Синтаксический сахар C#»
Дмитрий Верескун «Синтаксический сахар C#»
 
ADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developersADG Poznań - Kotlin for Android developers
ADG Poznań - Kotlin for Android developers
 
Visual Studio .NET2010
Visual Studio .NET2010Visual Studio .NET2010
Visual Studio .NET2010
 
Kotlin / Android Update
Kotlin / Android UpdateKotlin / Android Update
Kotlin / Android Update
 
Chapter04
Chapter04Chapter04
Chapter04
 
C# 6
C# 6C# 6
C# 6
 
Iron python
Iron pythonIron python
Iron python
 
U-SQL Killer Scenarios: Custom Processing, Big Cognition, Image and JSON Proc...
U-SQL Killer Scenarios: Custom Processing, Big Cognition, Image and JSON Proc...U-SQL Killer Scenarios: Custom Processing, Big Cognition, Image and JSON Proc...
U-SQL Killer Scenarios: Custom Processing, Big Cognition, Image and JSON Proc...
 
Novidades do c# 7 e 8
Novidades do c# 7 e 8Novidades do c# 7 e 8
Novidades do c# 7 e 8
 
SharePoint for the .NET Developer
SharePoint for the .NET DeveloperSharePoint for the .NET Developer
SharePoint for the .NET Developer
 
Visual studio 2008
Visual studio 2008Visual studio 2008
Visual studio 2008
 

More from Rodolfo Finochietti

Que hay de nuevo en 2013 en la plataforma Microsoft para desarrolladores
Que hay de nuevo en 2013 en la plataforma Microsoft para desarrolladoresQue hay de nuevo en 2013 en la plataforma Microsoft para desarrolladores
Que hay de nuevo en 2013 en la plataforma Microsoft para desarrolladores
Rodolfo Finochietti
 

More from Rodolfo Finochietti (20)

Introduction to Rust language programming
Introduction to Rust language programmingIntroduction to Rust language programming
Introduction to Rust language programming
 
C#: Past, Present and Future
C#: Past, Present and FutureC#: Past, Present and Future
C#: Past, Present and Future
 
Go
GoGo
Go
 
Re-bot-lution
Re-bot-lutionRe-bot-lution
Re-bot-lution
 
Azure Functions
Azure FunctionsAzure Functions
Azure Functions
 
Que hay de nuevo en Visual Studio 2013 y ASP.NET 5.1
Que hay de nuevo en Visual Studio 2013 y ASP.NET 5.1Que hay de nuevo en Visual Studio 2013 y ASP.NET 5.1
Que hay de nuevo en Visual Studio 2013 y ASP.NET 5.1
 
Proyectos de Base de Datos con Visual Studio 2013
Proyectos de Base de Datos con Visual Studio 2013Proyectos de Base de Datos con Visual Studio 2013
Proyectos de Base de Datos con Visual Studio 2013
 
ALM con Visual Studio y TFS 2013
ALM con Visual Studio y TFS 2013ALM con Visual Studio y TFS 2013
ALM con Visual Studio y TFS 2013
 
Que hay de nuevo en 2013 en la plataforma Microsoft para desarrolladores
Que hay de nuevo en 2013 en la plataforma Microsoft para desarrolladoresQue hay de nuevo en 2013 en la plataforma Microsoft para desarrolladores
Que hay de nuevo en 2013 en la plataforma Microsoft para desarrolladores
 
Introducción a ASP.NET Web API
Introducción a ASP.NET Web APIIntroducción a ASP.NET Web API
Introducción a ASP.NET Web API
 
ASP.NET MVC Workshop Día 3
ASP.NET MVC Workshop Día 3ASP.NET MVC Workshop Día 3
ASP.NET MVC Workshop Día 3
 
ASP.NET MVC Workshop Día 2
ASP.NET MVC Workshop Día 2ASP.NET MVC Workshop Día 2
ASP.NET MVC Workshop Día 2
 
ASP.NET MVC Workshop Día 1
ASP.NET MVC Workshop Día 1ASP.NET MVC Workshop Día 1
ASP.NET MVC Workshop Día 1
 
HTML5 Media Queries
HTML5 Media QueriesHTML5 Media Queries
HTML5 Media Queries
 
HTML5 Offline
HTML5 OfflineHTML5 Offline
HTML5 Offline
 
Nuevas características para Desarrollo Web en Visual Studio 2012 y ASP.NET MVC 4
Nuevas características para Desarrollo Web en Visual Studio 2012 y ASP.NET MVC 4Nuevas características para Desarrollo Web en Visual Studio 2012 y ASP.NET MVC 4
Nuevas características para Desarrollo Web en Visual Studio 2012 y ASP.NET MVC 4
 
Desarrollo de aplicaciones Windows 8 Modern UI con Visual Studio 2012
Desarrollo de aplicaciones Windows 8 Modern UI con Visual Studio 2012Desarrollo de aplicaciones Windows 8 Modern UI con Visual Studio 2012
Desarrollo de aplicaciones Windows 8 Modern UI con Visual Studio 2012
 
Desarrollo de Aplicaciones Metro en Windows 8
Desarrollo de Aplicaciones Metro en Windows 8Desarrollo de Aplicaciones Metro en Windows 8
Desarrollo de Aplicaciones Metro en Windows 8
 
Introducción a WPF
Introducción a WPFIntroducción a WPF
Introducción a WPF
 
HTML5 Geolocalizacion
HTML5 GeolocalizacionHTML5 Geolocalizacion
HTML5 Geolocalizacion
 

Recently uploaded

Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Recently uploaded (20)

Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 

Roslyn: el futuro de C#

  • 2.
  • 3. Fundamentos de un compilador
  • 4. class Program { void Main() { } } ▫ program.exe CSC - VBC
  • 5. 5
  • 6. 6
  • 8.
  • 10.
  • 11. Windows Convergence Universal projects Cloud Services .NET support for Azure Mobile Services Web apps Native compilation ASP.NET updates .NET Native Core .NET Runtime Compilers Next gen JIT (“RyuJIT”) SIMD .NET Compiler Platform (“Roslyn”) Languages innovation Azure and Windows Server Windows Desktop Openness Windows Store iOS and Android .NET in devices and services
  • 12.
  • 13. Editor Services Code Actions Classification Completion Outlining … Code Formatting Find All References Name Simplification … Symbol API Services Compiler Syntax Tree API Binding and Flow Analysis APIs Emit API Scripting API Workspace API
  • 14. Syntax Tree API – Nodes CompilationUnit TypeDeclaration MethodDeclaration class C { void M() { } }// C ▫ ParameterList Block var tree = CSharpSyntaxTree.ParseText("...");
  • 15. Syntax Tree API – Tokens CompilationUnit TypeDeclaration EOF class C { MethodDeclaration } void M ParameterList Block ( ) { } class C { void M() { } }// C ▫
  • 16. Syntax Tree API – Trivia CompilationUnit TypeDeclaration EOF class C { MethodDeclaration } SP EOL EOL // C void M ParameterList Block ( ) { } SPx4 SP EOL EOL SPx4 EOL SPx4 EOL class∙C { ∙∙∙∙void∙M() ∙∙∙∙{ ∙∙∙∙} }// C ▫
  • 17.
  • 18. Workspace API Host Environment Events (e.g. key presses) Workspace Solution Edit Edit Project Project Compilation Document Document Apply Solution2 Solutionn SyntaxTree
  • 19.
  • 20. C# 6
  • 21. public class Point(int x, int y) { public int X { get; } = x; public int Y { get; } = y; public double R { get; } = Math.Sqrt(x ^ x + y ^ y); public Point() : this(0, 0) { } public override string ToString() { return string.Format("({0},{1},{2})", X, Y, R); } }
  • 22. try { Task[] tasks = new Task[10]; for (int i = 0; i < 10; i++) { tasks[i] = Task.Factory.StartNew(() => DoSomeWork(10000000)); } var res = await Task.WhenAll(tasks); } catch (AggregateException e) if (e.InnerExceptions.Count > 2) { await WriteStatus(“filtered exception"); } finally { await WriteStatus(“finished"); }
  • 23.
  • 24.
  • 26.
  • 29. ¡ Gracias! rodolfof@lagash.com http://shockbyte.net