diff options
Diffstat (limited to 'mcs/class/Microsoft.Build/Microsoft.Build.Construction/ProjectWhenElement.cs')
-rw-r--r-- | mcs/class/Microsoft.Build/Microsoft.Build.Construction/ProjectWhenElement.cs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mcs/class/Microsoft.Build/Microsoft.Build.Construction/ProjectWhenElement.cs b/mcs/class/Microsoft.Build/Microsoft.Build.Construction/ProjectWhenElement.cs index 68040f52c2..0d7331afcb 100644 --- a/mcs/class/Microsoft.Build/Microsoft.Build.Construction/ProjectWhenElement.cs +++ b/mcs/class/Microsoft.Build/Microsoft.Build.Construction/ProjectWhenElement.cs @@ -29,6 +29,7 @@ using System; using System.Collections.Generic; using System.Linq; +using System.Xml; using Microsoft.Build.Exceptions; using Microsoft.Build.Internal; @@ -57,9 +58,9 @@ namespace Microsoft.Build.Construction internal override string XmlName { get { return "When"; } } - internal override ProjectElement LoadChildElement (string name) + internal override ProjectElement LoadChildElement (XmlReader reader) { - switch (name) { + switch (reader.LocalName) { case "PropertyGroup": var property = ContainingProject.CreatePropertyGroupElement (); AppendChild (property); @@ -74,7 +75,7 @@ namespace Microsoft.Build.Construction return when; default: throw new InvalidProjectFileException (string.Format ( - "Child \"{0}\" is not a known node type.", name)); + "Child \"{0}\" is not a known node type.", reader.LocalName)); } } } |