diff options
Diffstat (limited to 'mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs')
-rw-r--r-- | mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs | 26 |
1 files changed, 3 insertions, 23 deletions
diff --git a/mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs b/mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs index 7f27047ddc9..419b45b30f7 100644 --- a/mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs +++ b/mcs/class/System.XML/System.Xml.Schema/BuiltInDatatype.cs @@ -1631,30 +1631,10 @@ namespace Mono.Xml.Schema {
public string value;
- static bool HasValidScheme (string src)
- {
- int idx = src.IndexOf (':');
- if (idx < 0)
- return false;
- for (int i = 0; i < idx; i++) {
- switch (src [i]) {
- case '+':
- case '-':
- case '.':
- continue;
- default:
- if (Char.IsLetterOrDigit (src [i]))
- continue;
- return false;
- }
- }
- return true;
- }
-
- // MS BUG: Some strings that contain ':' might result in
- // exception (MS.NET looks implemented as such).
+ // LAMESPEC: In this way, some strings that contain ':' might
+ // result in exception (MS.NET looks implemented as such).
public XmlSchemaUri (string src)
- : this (src, HasValidScheme (src))
+ : this (src, src.IndexOf (':') > 0)
{
}
|