SlideShare a Scribd company logo
C# 4.0 Language EnhancementsSankarsan Bose11th October 2009
Agenda Journey of C#
 Current Trends
 C# 4.0 Features
 Dynamic Objects
 Named And Optional Parameters
 Covariance And Contravariance
 Improved COM InterOp Journey of C#???Functional + LINQGenericsStatic Language + Managed Code
Current TrendsC#
C# 4.0 Features Dynamic Programming
 Optional and Named Parameters
 Co- and Contra-variance
 Improved COM Interoperability Dynamic ProgrammingRuby Code Sample  No type is defined
  Stores string value
  “+” operator concatenates
Assigned int values
“+” operator  addsType  Determined At Runtime Based On Type Of Value Stored
Dynamic ProgrammingRuby Code Sample  Both classes define “print”
  Exactly same signature
  No type defined for parameter “p”
  Any object supporting method “print”  is a valid input
This is called “Duck Typing”Method To Be Invoked Is Decided At Runtime
Dynamic ProgrammingDynamic Method Dispatch in C# (Before 4.0)Both are staticallytyped as IOfficeDocument
Dynamic ProgrammingDynamically Typed Objects in C# 4.0  New keyword  “dynamic”
 Statically Typed as “dynamic”
 Actual type determined at runtimeDynamic Method Invocation
Dynamic ProgrammingPros No risk of brittle class hierarchy
 Need not implement all methods of interface
 More flexible , highly productiveCons Developer needs thorough understanding of codebase
 Misuse might lead to poor maintainabilityDynamic ProgrammingDemo
Dynamic ProgrammingC# is a statically typedlanguageHow we are making it dynamic ???Here Comes DLRDynamic Language Runtime
Dynamic ProgrammingDLR is additional libraries to fit the dynamic languages into the CLR Store program/code as data
 Caching mechanism for dynamic call
 Provide language specific supportDynamic ProgrammingClass Generated Under The Hood  CallSite is created before method call
Actual method call is delegated to CallSite

More Related Content

What's hot (18)

PPTX
2CPP02 - C++ Primer
Michael Heron
 
PDF
New c sharp4_features_part_iv
Nico Ludwig
 
PPT
Intro dotnet
shuklagirish
 
PDF
Boogie 2011 Hi-Lite
AdaCore
 
PPTX
C#4.0 features
Yaswanth Babu Gummadivelli
 
PPT
Workin ontherailsroad
Jim Jones
 
PPT
WorkinOnTheRailsRoad
webuploader
 
PPT
a quick Introduction to PyPy
Kai Aras
 
PPTX
Modern Programming Languages - An overview
Ayman Mahfouz
 
ZIP
An Introduction to PyPy
Michael Hudson-Doyle
 
PDF
PyPy
ESUG
 
PDF
How does intellisense work?
Adam Friedman
 
PDF
llvm-py: Writing Compilers In Python
mdevan
 
KEY
Dart: A Replacement for JavaScript and Why You Should Care
Kevin Gisi
 
PPTX
Dynamic languages for .NET CLR
py_sunil
 
PDF
F# for Scala developers
Alfonso Garcia-Caro
 
PDF
An Objective-C Primer
Babul Mirdha
 
2CPP02 - C++ Primer
Michael Heron
 
New c sharp4_features_part_iv
Nico Ludwig
 
Intro dotnet
shuklagirish
 
Boogie 2011 Hi-Lite
AdaCore
 
Workin ontherailsroad
Jim Jones
 
WorkinOnTheRailsRoad
webuploader
 
a quick Introduction to PyPy
Kai Aras
 
Modern Programming Languages - An overview
Ayman Mahfouz
 
An Introduction to PyPy
Michael Hudson-Doyle
 
PyPy
ESUG
 
How does intellisense work?
Adam Friedman
 
llvm-py: Writing Compilers In Python
mdevan
 
Dart: A Replacement for JavaScript and Why You Should Care
Kevin Gisi
 
Dynamic languages for .NET CLR
py_sunil
 
F# for Scala developers
Alfonso Garcia-Caro
 
An Objective-C Primer
Babul Mirdha
 

Similar to Community Tech Days C# 4.0 (20)

PPSX
Introduction to c sharp 4.0 and dynamic
Gieno Miao
 
PPT
devLink - What's New in C# 4?
Kevin Pilch
 
PPTX
Whats New In C# 4 0 - NetPonto
Paulo Morgado
 
PPTX
PDC Video on C# 4.0 Futures
nithinmohantk
 
PPTX
2.dynamic
bashcode
 
PPTX
Dynamic Language Performance
Kevin Hazzard
 
PPTX
What\'s New in C# 4.0
Eyal Vardi
 
PPT
Lo Mejor Del Pdc2008 El Futrode C#
Juan Pablo
 
PDF
New c sharp4_features_part_ii
Nico Ludwig
 
ODP
New c sharp4_features_part_iii
Nico Ludwig
 
PDF
Dynamic Binding in C# 4.0
Buu Nguyen
 
PPT
What To Expect With C
Joseph Guadagno
 
PPTX
Whats New In C Sharp 4 And Vb 10
KulveerSingh
 
PPTX
Visual Studio 2010 and .NET 4.0 Overview
bwullems
 
PPTX
Dynamic C#
Antya Dev
 
PPTX
Dynamic in C# 4.0
morrisBahrami
 
PPTX
Overview Of .Net 4.0 Sanjay Vyas
rsnarayanan
 
PPTX
.NET 4 Demystified - Sandeep Joshi
Spiffy
 
PPT
MTaulty_DevWeek_VS2010
ukdpe
 
PPT
MTaulty_DevWeek_VS2010
ukdpe
 
Introduction to c sharp 4.0 and dynamic
Gieno Miao
 
devLink - What's New in C# 4?
Kevin Pilch
 
Whats New In C# 4 0 - NetPonto
Paulo Morgado
 
PDC Video on C# 4.0 Futures
nithinmohantk
 
2.dynamic
bashcode
 
Dynamic Language Performance
Kevin Hazzard
 
What\'s New in C# 4.0
Eyal Vardi
 
Lo Mejor Del Pdc2008 El Futrode C#
Juan Pablo
 
New c sharp4_features_part_ii
Nico Ludwig
 
New c sharp4_features_part_iii
Nico Ludwig
 
Dynamic Binding in C# 4.0
Buu Nguyen
 
What To Expect With C
Joseph Guadagno
 
Whats New In C Sharp 4 And Vb 10
KulveerSingh
 
Visual Studio 2010 and .NET 4.0 Overview
bwullems
 
Dynamic C#
Antya Dev
 
Dynamic in C# 4.0
morrisBahrami
 
Overview Of .Net 4.0 Sanjay Vyas
rsnarayanan
 
.NET 4 Demystified - Sandeep Joshi
Spiffy
 
MTaulty_DevWeek_VS2010
ukdpe
 
MTaulty_DevWeek_VS2010
ukdpe
 
Ad

Recently uploaded (20)

PPTX
OA presentation.pptx OA presentation.pptx
pateldhruv002338
 
PPTX
Agile Chennai 18-19 July 2025 | Workshop - Enhancing Agile Collaboration with...
AgileNetwork
 
PDF
Brief History of Internet - Early Days of Internet
sutharharshit158
 
PDF
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
PPTX
AI Code Generation Risks (Ramkumar Dilli, CIO, Myridius)
Priyanka Aash
 
PDF
introduction to computer hardware and sofeware
chauhanshraddha2007
 
PDF
Per Axbom: The spectacular lies of maps
Nexer Digital
 
PPTX
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
PPTX
IT Runs Better with ThousandEyes AI-driven Assurance
ThousandEyes
 
PDF
Tea4chat - another LLM Project by Kerem Atam
a0m0rajab1
 
PDF
Data_Analytics_vs_Data_Science_vs_BI_by_CA_Suvidha_Chaplot.pdf
CA Suvidha Chaplot
 
PDF
Structs to JSON: How Go Powers REST APIs
Emily Achieng
 
PPTX
The Future of AI & Machine Learning.pptx
pritsen4700
 
PDF
Researching The Best Chat SDK Providers in 2025
Ray Fields
 
PPTX
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
PDF
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
PPTX
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
PPTX
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
PDF
Market Insight : ETH Dominance Returns
CIFDAQ
 
PPTX
Simple and concise overview about Quantum computing..pptx
mughal641
 
OA presentation.pptx OA presentation.pptx
pateldhruv002338
 
Agile Chennai 18-19 July 2025 | Workshop - Enhancing Agile Collaboration with...
AgileNetwork
 
Brief History of Internet - Early Days of Internet
sutharharshit158
 
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
AI Code Generation Risks (Ramkumar Dilli, CIO, Myridius)
Priyanka Aash
 
introduction to computer hardware and sofeware
chauhanshraddha2007
 
Per Axbom: The spectacular lies of maps
Nexer Digital
 
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
IT Runs Better with ThousandEyes AI-driven Assurance
ThousandEyes
 
Tea4chat - another LLM Project by Kerem Atam
a0m0rajab1
 
Data_Analytics_vs_Data_Science_vs_BI_by_CA_Suvidha_Chaplot.pdf
CA Suvidha Chaplot
 
Structs to JSON: How Go Powers REST APIs
Emily Achieng
 
The Future of AI & Machine Learning.pptx
pritsen4700
 
Researching The Best Chat SDK Providers in 2025
Ray Fields
 
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
Market Insight : ETH Dominance Returns
CIFDAQ
 
Simple and concise overview about Quantum computing..pptx
mughal641
 
Ad

Community Tech Days C# 4.0