Yesterday, I delivered a session titled “What’s new in C# 4.0?” after a session by Guy Burstein on “First look at Visual Studio 2010”.
Thank you all for attending. I apologise for not using all the feedbacks to select winners for the books – sorry, guys! I’ll pay attention next time (probably lack of food).
Some notes that came up during the session:
1. The misbehavior on the DynamicXmlElement class was due to a small oversight: I wrote this code when only one element existed:
case 1:
result = elements.First();
break;
which returns the element as is (which is an XElement, not what we want). It should have been:
case 1:
result = new DynamicXmlElement(elements.First());
break;
So it continues to be a DynamicXmlElement object. Again, lack of food.
2. The other question I left somewhat open, is regarding caching in the ExpandoObject example. Well, no caching is possible – no special layer there, the code must run each time and do the right thing.
The code samples will be available soon in the usual location as Guy described.