1
Votes

Web 2.0 | Dynamic Typing in C# 4.0

published 349 days, 1 hour, 1 minute ago posted by farooqkaiserfarooqkaiser 358 days, 14 hours, 24 minutes ago
Monday, August 17, 2009 2:53:36 AM GMT Friday, August 07, 2009 1:30:42 PM GMT

C# 4.0 introduces a new static type called dynamic. When an instance variable is defined with the type dynamic, the compiler ignores the call and won't complain. These actions are picked up at runtime. Here are comparison with C# 3.0 and C# 4.0 using Dynamic Types. Let's say I have the following code in C# 3.0     // will not work in c# 3.0        object o = "farooq";        Console.Write(o.Insert(o.Length, " Kaiser ")); 

     

// will work in c# 3.0       object o = "farooq";       str...

Category: Technology | Clicked: 1 | | Source: www.fairnet.com | show counter code
Tags: .NET 4 .0, C# 4.0

No comments yet, be the first one to post comment.

To post your comment please login or signup