C# 4.0 - Questions and reasons behind the answers
- Posted: Nov 11, 2008 at 9:15 AM
- 101,079 Views
- 14 Comments
Loading User Information from Channel 9
Something went wrong getting user information from Channel 9
Loading User Information from MSDN
Something went wrong getting user information from MSDN
Loading Visual Studio Achievements
Something went wrong getting the Visual Studio Achievements
Right click “Save as…”
Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation,
please create a new thread in our Forums,
or
Contact Us and let us know.
Follow the Discussion
Oops, something didn't work.
What does this mean?
Following an item on Channel 9 allows you to watch for new content and comments that you are interested in. You need to be signed in to Channel 9 to use this feature.What does this mean?
Following an item on Channel 9 allows you to watch for new content and comments that you are interested in and view them all on your notifications page.sign up for email notifications?
I completely agree with the question on covariant return types. When I met Anders at the PDC bookstore I really tried to get the message across and I've been pushing the request for a long time (as have numerous other people in the community).
When can we have a downloadable document about the C#4 language? There is already one for C#3. I am looking forward for a downloadable document for C#4.
var xml =
@"<Users>
<User>user1</User>
<User>user2</User>
</Users>".ToXML();
Console.WriteLine(xml.ToString());
public static XElement ToXML(this string xmlString)
{
return XElement.Parse(xmlString);
}
But that lacks two major things, compiler support and designer support. Naturally, it becomes a slippery slope of what meta languages to support as the next question becomes support for JSON and M. I think M makes this more interesting as I think we will need compiler support for that. So should M, JSON, and XML have compiler support in c#? Why or why not? Could these be opt-in/opt-out extentions to the language?
No difficulties in having to line up ending tags. Its XML exploiting the C# parser.
Will Visual C++ status quote be enough to overcome the appeal of the D programming language in 2010?or is C# going to be unleashed?
Why doesn't Visual Studio provide for two forms of compilation. For example the exiting just in time and full compilation of the MSIL to machine code. I really see that C++ at this stage only serves for the purpose of maintaining legacy code. The incarnation of C++ was a hack and will continue to grow as a hack. .Net languages (in particular C#) for one should take full charge of future development in both desktop, web and yes system development. D programming language is already making an impression on a small but growing C++ community. D programming languages has syntactic appeal of C# and the horse power of C/C++. So what is the constraint, religion or technical feasibility. DotNet languages will be competing against the up an coming D programming languages sooner or later for development of system software and embedded systems. Again I say C++ is dead weight and should only be relevant for legacy code (in other words C++ will soon be Cobol). C# (all .net lingos) can easily take the manto if Visual Studio provided for this option and full support for "producing" applications that are true platform independent.
Well, I can see a some nice scenarios to use this.

OR even more useful, dynamics for class names also.
But I had hoped for something much more powerful
private string Foo(int x)
{
return x + 10;
}
public DoSomeThing(Method name)
{
var fooValue = name(10);
}
public Caller()
{
DoSomeThing("Foo");
}
That's what I call dynamic
Thanks for this discussion. As we train ourselves to think in terms of Abstraction when programming we many time find ourselves purposely genericizing the type. Passing objects in and out of methods becomes attractive with repsect to Abstraction. The problem of course is in the reconstruction of the Object into statically typed objects just for the sake of calling a method. As you mentioned using the Reflection class does indeed become messy (and actually predates things such as the HTML DOM (for example MethodInfo and FieldInfo) are not terms used within the HTMLDOM, so we have to convert mentally when trying to work with HTML DOM that a Reflection.MethodInfo = DOM.FiledAttirbute (or something similar). It requires speding too much time in the debugger's immediate window trying to ferret this stuff out. With Dynamic it looks like we will immensly ease this problem. Thanks again.
Remove this comment
Remove this thread
close